feat(aliases): cancel the run before retriggering its failed roles

Retriggering leaves the original run alive, so its remaining jobs keep runner
slots while the newly triggered ones queue behind them. Force-cancelling first
frees those slots.

The cancel is not chained with &&: the usual case is a run that already
finished, where force-cancel reports an error, and chaining would block the
trigger exactly when it is wanted. A failed cancel prints a line and the
trigger proceeds.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
kevinveenbirkenbachandClaude Opus 5 committed 2026-08-10 20:28:38 +02:00
1 parent 305d9341d5
commit da7b80b890
1 file changed
+1 -1
+1 -1
View File
@@ -16,7 +16,7 @@ alias i8ceco='m clean-container-owned'
alias i8cepa='m clean-pycache-dirs'
alias i8cesa='m clean-stale-nfs'
alias i8cesu='m clean-sudo'
alias i8cifail='__i8cifail(){ [ -z "${1:-}" ] && { echo "usage: i8cifail <run-id|url> [total|swarm|compose]" >&2; return 2; }; infinito administration deploy ci trigger --failed "${2:-total}" --run "$1"; }; __i8cifail' # retrigger failed and never-deployed priority roles of run $1 (id or url), scope $2 (default total), reproducing that run's configuration
alias i8cifail='__i8cifail(){ [ -z "${1:-}" ] && { echo "usage: i8cifail <run-id|url> [total|swarm|compose]" >&2; return 2; }; ghaf "$1" || echo "i8cifail: force-cancel of run $1 reported nothing to cancel; continuing" >&2; infinito administration deploy ci trigger --failed "${2:-total}" --run "$1"; }; __i8cifail' # retrigger failed and never-deployed priority roles of run $1 (id or url), scope $2 (default total), reproducing that run'"'"'s configuration; force-cancels the run first so it stops holding runner slots
alias i8cifo='__i8cifo(){ [ -z "${1:-}" ] && { echo "usage: i8cifo <run-id|url> [total|swarm|compose]" >&2; return 2; }; infinito administration deploy ci trigger --failed "${2:-total}" --strict --run "$1"; }; __i8cifo' # like i8cifail but only hard-failed roles, excluding cancelled/aborted; scope $2 (default total)
alias i8cire='__i8cire(){ make quality && gips && i8cifail "$1" swarm; }; __i8cire'
alias i8co='m compose-deploy'