GRM-51: ci: add shell safety and workflow_dispatch fix to all workflows

This commit is contained in:
emil
2026-06-22 01:11:37 +00:00
parent 1b3c3f6ca8
commit 5cd7c15d11
3 changed files with 25 additions and 1 deletions
+13
View File
@@ -31,6 +31,7 @@ jobs:
- name: Check if this is a release commit
id: check
run: |
set -euo pipefail
MSG=$(git log -1 --pretty=%s)
echo "Commit message: $MSG"
if echo "$MSG" | grep -qE '^release: v[0-9]+\.[0-9]+\.[0-9]+'; then
@@ -55,6 +56,7 @@ jobs:
run: make setup
- name: Install git-cliff
run: |
set -euo pipefail
GIT_CLIFF_VERSION="2.13.0"
URL="https://github.com/orhun/git-cliff/releases/download/v${GIT_CLIFF_VERSION}/git-cliff-${GIT_CLIFF_VERSION}-x86_64-unknown-linux-gnu.tar.gz"
TMPDIR="$(mktemp -d)"
@@ -66,12 +68,14 @@ jobs:
"$HOME/.local/bin/git-cliff" --version
- name: Configure git
run: |
set -euo pipefail
git config user.name "grm-ci-bot"
git config user.email "grm-ci-bot@oblachno.fyi"
- name: Run release
env:
PYTHONPATH: .
run: |
set -euo pipefail
. .venv/bin/activate
python3 scripts/ci/release.py
@@ -91,6 +95,7 @@ jobs:
REPO_TOKEN: ${{ secrets.REPO_TOKEN }}
PYTHONPATH: src
run: |
set -euo pipefail
. .venv/bin/activate
python3 scripts/ci/sync_wiki.py --repo "${{ github.repository }}" --strict
@@ -108,12 +113,19 @@ jobs:
run: make setup
- name: Generate badge SVG files
run: |
set -euo pipefail
. .venv/bin/activate
python3 scripts/generate_badges.py --output-dir .badges/
# Verify badges were generated
if [ -z "$(ls -A .badges/ 2>/dev/null)" ]; then
echo "::error::No badge SVG files generated"
exit 1
fi
- name: Push badges to badges branch
env:
PRE_COMMIT_ALLOW_NO_CONFIG: "1"
run: |
set -euo pipefail
git config user.name "gitea-actions-bot"
git config user.email "actions@oblachno.fyi"
git checkout --orphan badges
@@ -139,6 +151,7 @@ jobs:
VIKUNJA_TOKEN: ${{ secrets.VIKUNJA_TOKEN }}
PYTHONPATH: src
run: |
set -euo pipefail
python3 scripts/ci/post_merge.py \
"$(git log -1 --pretty=%B)" \
--commit-sha "$(git rev-parse HEAD)"