aboutsummaryrefslogtreecommitdiff
path: root/share/aux/cases/cp_all
diff options
context:
space:
mode:
authorEuAndreh <eu@euandre.org>2023-04-04 06:48:15 -0300
committerEuAndreh <eu@euandre.org>2023-04-04 06:48:15 -0300
commitcb6eb5fa33cbab8a30635ffdbaed853ea82d3962 (patch)
tree91b88f972df0f9564802602046bd46b625425d68 /share/aux/cases/cp_all
parentbin/aux: Update path to repository db (diff)
downloaddotfiles-cb6eb5fa33cbab8a30635ffdbaed853ea82d3962.tar.gz
dotfiles-cb6eb5fa33cbab8a30635ffdbaed853ea82d3962.tar.xz
share/aux/cases/*/aux/{ci/report.sh,po4a-cfg}.sh: Update and improve help string
Diffstat (limited to 'share/aux/cases/cp_all')
-rwxr-xr-xshare/aux/cases/cp_all/aux/ci/report.sh34
1 files changed, 18 insertions, 16 deletions
diff --git a/share/aux/cases/cp_all/aux/ci/report.sh b/share/aux/cases/cp_all/aux/ci/report.sh
index 2f36ad5..0a0a0ae 100755
--- a/share/aux/cases/cp_all/aux/ci/report.sh
+++ b/share/aux/cases/cp_all/aux/ci/report.sh
@@ -4,7 +4,7 @@ set -eu
usage() {
cat <<-'EOF'
Usage:
- aux/ci/report.sh -n NAME -o OUTDIR
+ aux/ci/report.sh -o OUTDIR
aux/ci/report.sh -h
EOF
}
@@ -14,7 +14,6 @@ help() {
Options:
- -n NAME the name of the project
-o OUTDIR the directory where to place the generated files
-h, --help show this message
@@ -31,23 +30,30 @@ help() {
from refs/notes/ci-logs.
On a CI run that generated the numbers from 1 to 10, for a file named
- 'my-ci-run-2020-01-01-deadbeef.log' that exited successfully, the
- expected output on the target directory "public" is:
+ 'my-ci-run-2020-01-01-deadbeef.log' that exited successfully, ran for
+ 15 seconds and was deployed to production, the expected output on the
+ target directory "public" is:
$ tree public/
public/
index.html
data/
- my-ci-run-2020-01-01-deadbeef.log
+ 2020-01-01T01:00:00-deadbeef.log
...
logs/
- my-ci-run-2020-01-01-deadbeef.log
+ 2020-01-01T01:00:00-deadbeef.log
...
- $ cat public/data/my-ci-run-2020-01-01-deadbeef.log
- 0 deadbeef my-ci-run-2020-01-01-deadbeef.log
+ $ cat public/data/2020-01-01T01:00:00-deadbeef.log
+ status 0
+ sha deadbeef
+ filename deadbeef 2020-01-01T01:00:00-deadbeef.log
+ duration 15
+ timestamp 2020-01-01T01:00:00
+ to-prod true
+ refname refs/heads/main
- $ cat public/logs/my-ci-run-2020-01-01-deadbeef.log
+ $ cat public/logs/2020-01-01T01:00:00-deadbeef.log
1
2
3
@@ -61,7 +67,7 @@ help() {
The generated 'index.html' is a webpage with the list of all known
CI runs, their status, a link to the commit and a link to the
- log file.
+ log and data files.
To enable fetching these refs by default, do so in the git config:
@@ -72,7 +78,7 @@ help() {
Generate the report on the 'www' directory:
- $ report -o www
+ $ sh aux/ci/report.sh -o www
EOF
}
@@ -92,11 +98,8 @@ for flag in "$@"; do
esac
done
-while getopts 'n:o:h' flag; do
+while getopts 'o:h' flag; do
case "$flag" in
- n)
- NAME="$OPTARG"
- ;;
o)
OUTDIR="$OPTARG"
;;
@@ -114,7 +117,6 @@ shift $((OPTIND - 1))
. aux/lib.sh
-eval "$(assert_arg "${NAME:-}" '-n NAME')"
eval "$(assert_arg "${OUTDIR:-}" '-o OUTDIR')"