Every second place I've worked at had a TIME-TRACKING SYSTEM. Because managers like their bar-charts, and pie charts, and all sorts of charts.

And in order to build the charts - everyone gotta LOG TIME, time he's been working for, time he was in meetings, time he spent logging time... RIDICULOUS

Of course SOMEONE could have spent 10 minutes THINKING and automated the fucking thing, but of course that would be WAY TOO MUCH THINKING, so hundreds of people do it manually every day (more like once a month, making shit up)

Let's brain-storm this A BIT, mmokay?

Implying you use GIT and ANY sort of ticket-system

So the first idea of mine was: LETS QUERY GIT history, that would only help the developers, but I am a developer!! Even if 30% of headcount are developers - that's still SO MUCH FRUSTRATION AND GRIND TAKEN AWAY!

We'll need

  • a user name - go execute git config user.name
  • the date we query for (i assume we log this stuff daily)

Having these two, just execute:

git log --author="${name}" --pretty=format:"${FORMAT}

grep time deltas inbetween commits, last commit gets 8hours - ${total time inbetween the rest}

And thats pretty much it! This data is sufficient to log something like:

Your pretty name

Even prettier day of the week

  • TICKET-001 - Making buttons real big - 2 hrs
  • TICKET-002 - Making sliders real small - 4 hrs
  • TICKET-003 - Making buttons real big - (8 - 6 = 2) hrs

Thats exactly what i did months ago, dumping these into a text file/feeding it to a greesemonkey userscript that CLICKS AROUND THE TIMETRACKING SYSTEM.

Ok, mr. smart-ass, YOU DEVELOPERS always think its all simple. What about all the other, MORE Important roles! IT RECRUITERS, IT BARISTAS, IT OFFICE MANAGERS? Have you thought of them?

Actually i did!

Implying you use Atlassian JIRA

So the trick here would be querying ALL TICKETS that THE CURRENT USER has moved from STATUS_A to STATUS_B during the day.

if THERE'RE NONE - log 8 hours of ones that were assigned to him and had status IN PROGRESS

ROCKET FUCKIN SCIENCE, no one should have all that power

A JQL query for a QA engineer might look like:

(project="Your Cool Banking App" OR project ="Your other project" ) AND sprint in openSprints() AND status changed BY (${yourJiraName}) TO ("Integration", "Done", "Closed" ) AFTER startOfDay()

I would query this via jira REST api, and if the results are an empty array - query

(project="Your Cool Banking App" OR project ="Your other project" ) AND sprint in openSprints() AND status = "In progress" and assignee=(${yourJiraName})

Not quite sure about time, maybe it can be queried form the history, maybe we'd have to fake it subtracting from 8 hrz again.

but how one can query these OUTSIDE of jira server ui?

jira API is all open, go execute a curl/fetch

const query = `https://jira.my-company-name.io/rest/api/latest/search?jql=${JQL}`
   headers: { 'Authorization': `Basic ${base64.encode(your_username + ':' + password)}` },


Export it from the outlook via SOAP, you dum-dum!

I mean seriously, NO ONE SHOULD EVER FILL FORMS LIKE THAT MANUALLY, if you have all this info in JIRA and GIT and OUTLOOK anyways. The company should have booked 1-2 engineers for 2-3 days, automate it once and for all and just GET THEIR PRECIOUS DATA!

Guess FORCING people to write esseys about the way they spent their working day is supposed to drive the creativity of a person.

27-03-2019, jira, git, automation