Learning jq through a timesheet app
Paulo Jerônimo <pj@paulojeronimo.com>, 2021-04-23 15:25:27 -0300
Table of Contents
Learning jq through a timesheet app
Running the timesheet app
jq step by step
Generate some JSON files from YAML files
How to pretty-print the data (files in YAML format) and the generated JSON files?
See the timesheet for the week 07 in 2021
In which weekdays do we have an entry for the week 2021-07?
Do we have an entry for …
How to force jq returns a valid exit code to shell?
Can we see the entries for Monday and for Wednesday?
How can I see the start/end times for Monday?
But we can have more than one start/end time for the same day. Is this right?
How to convert a string that represents a time in order to use it in time calculations?
Can we pass a "time string" to jq?
Something gets wrong …
Parsing a date/time (converting it from a string)
Converting a date/time to a string
How to calculate a duration (the time between start/end times)?
How to create a jq library?
How to use a jq library?
How to convert "Year-WeekNumber.DayOfWeek" to date?
References
Converting a date/time to a string
jq 'strftime("%H:%M")' tmp/date