1
0
Fork 0

clean up shell scripts

This commit is contained in:
Luca Bilke 2024-10-17 11:18:27 +02:00
commit 890dc7638e
Signed by: luca
GPG key ID: F6E11C9BAA7C82F5
3 changed files with 539 additions and 514 deletions

File diff suppressed because it is too large Load diff

View file

@ -1,5 +1,4 @@
#!/bin/sh #!/bin/sh
# shellcheck disable=2154
term= term=
[ -n "$SCRATCHPAD" ] && { [ -n "$SCRATCHPAD" ] && {

View file

@ -1,5 +1,4 @@
#!/bin/sh #!/bin/sh
# shellcheck disable=2089,2090
year=$1 year=$1
month=$2 month=$2
@ -25,12 +24,12 @@ filters='[
]' ]'
curl -s \ curl -s \
-u "apikey:${API_KEY}" \ -u "apikey:${API_KEY}" \
-G "${API_URL}/api/v3/time_entries" \ -G "${API_URL}/api/v3/time_entries" \
--data-urlencode "filters=${filters}" \ --data-urlencode "filters=${filters}" \
--data-urlencode "pageSize=${PAGE_SIZE}" | --data-urlencode "pageSize=${PAGE_SIZE}" |
jq -r '._embedded.elements | map(.hours) | join(" ")' | jq -r '._embedded.elements | map(.hours) | join(" ")' |
awk '{ awk '{
gsub(/PT/, ""); gsub(/PT/, "");
gsub(/H/, "H "); gsub(/H/, "H ");
gsub(/M/, "M "); gsub(/M/, "M ");