The `/ci-all` workflow detects the project stack, blocks runs on protected branches, and stops before pushing if a required test or type check fails. It can skip tests or include configured E2E tests, then pushes the branch and reports the GitLab or GitHub pipeline URL. It is intended to run when invoked before opening a PR.
Runs everything in order: local tests → type check → push → pipeline URL.
One /ci-all replaces: manual tests + git push + copying the pipeline URL. It pushes, so it runs only when you invoke it.
if [ -f "uv.lock" ]; then STACK="python"
elif [ -f "pnpm-lock.yaml" ]; then STACK="node"
elif [ -f "package-lock.json" ]; then STACK="node-npm"
elif [ -f "Cargo.toml" ]; then STACK="rust"
fiRefuse to run on main, master or production: tell the user to switch to a feature branch.
Run each command on its own and stop at the first failure: a failing step means do not push.
Python (uv/pytest):
uv run pytest --tb=short -q
# Failure → STOP + print failing testsNode (pnpm/vitest):
pnpm vitest run
pnpm tsc --noEmit
# Failure → STOPRust:
cargo test --quiet 2>&1If --skip-tests is passed → skip to step 2. If --e2e is passed, also run the project's E2E command when the repo defines one (for example a test:e2e script), and say so when none exists.
BRANCH=$(git branch --show-current)
# Verify commits exist to push
AHEAD=$(git rev-list --count origin/$BRANCH..HEAD 2>/dev/null || echo "1")
if [ "$AHEAD" = "0" ]; then
echo "Branch already up to date on origin."
else
git push origin "$BRANCH"
fiREMOTE=$(git remote get-url origin)
WEB_URL=$(echo "$REMOTE" | sed 's/git@gitlab\.com:/https:\/\/gitlab.com\//' | sed 's/\.git$//')
echo "Pipeline: $WEB_URL/-/pipelines?ref=$BRANCH"
# Optional: live status via glab CLI
if command -v glab &>/dev/null; then
sleep 3
glab ci status --branch "$BRANCH" 2>/dev/null || true
fiREMOTE=$(git remote get-url origin)
WEB_URL=$(echo "$REMOTE" | sed 's/git@github\.com:/https:\/\/github.com\//' | sed 's/\.git$//')
echo "Actions: $WEB_URL/actions?query=branch%3A$BRANCH"
# Optional: live status via gh CLI
if command -v gh &>/dev/null; then
sleep 5
gh run list --branch "$BRANCH" --limit 3 2>/dev/null || true
fiCI: my-app (Node/Vitest)
──────────────────────────
① Local tests
✅ 47 passed in 8.2s
② Type check
✅ No errors
③ Push
✅ origin/feat/my-feature
④ Pipeline
🔗 https://gitlab.com/org/my-app/-/pipelines?ref=feat/my-feature
Next step: open a PR or MR on the forge.If tests fail:
CI: my-api (Python/pytest)
────────────────────────────
① Local tests
❌ 2 failed
FAILED tests/test_orders.py::TestOrderService::test_refund_validation
AssertionError: expected 400, got 500
→ Fix tests before pushing. Pipeline not triggered./ci-all
/ci-all --skip-tests # push without re-running tests
/ci-all --e2e # include E2E tests (if configured)Target: $ARGUMENTS
f97e4f7
uvuv runuv run pytestpnpmpnpm vitestpnpm vitest runpnpm tsccargocargo testgitgit branchgit rev-listgit pushgit remotegit remote get-urlechosedsleepglabglab ciglab ci statusghgh rungh run listpytestvitesttscBashIf you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.