mirror of
https://github.com/simonmichael/hledger.git
synced 2024-11-07 21:15:19 +03:00
11 lines
393 B
Plaintext
11 lines
393 B
Plaintext
|
#!/usr/bin/env bash
|
||
|
# ciwatch [INTERVALSECS]
|
||
|
# Watch the latest Github actions run until it completes, returning the exit status.
|
||
|
|
||
|
INTERVAL="${1:-10}"
|
||
|
|
||
|
#LATESTRUN=$(gh run list -L1 --json databaseId -q .[0].databaseId)
|
||
|
LATESTRUNNING=$(gh run list --json status,databaseId -q '.[] | select(.status=="completed").databaseId' | head -1)
|
||
|
|
||
|
gh run watch -i"$INTERVAL" "$LATESTRUNNING" --exit-status
|