Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
48 changes: 48 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,50 @@ concurrency:
cancel-in-progress: true

jobs:

changes:
name: Relevant changes
runs-on: ubuntu-latest

outputs:
run: ${{ steps.filter.outputs.run }}

steps:
- name: Checkout
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
with:
persist-credentials: false
fetch-depth: 0

- name: Detect relevant changes
id: filter
env:
EVENT_NAME: ${{ github.event_name }}
BEFORE_SHA: ${{ github.event.before }}
BASE_SHA: ${{ github.event.pull_request.base.sha }}
run: |
if [ "$EVENT_NAME" = "pull_request" ]; then
BASE="$BASE_SHA"
elif [ "$BEFORE_SHA" = "0000000000000000000000000000000000000000" ]; then
echo "run=true" >> "$GITHUB_OUTPUT"
exit 0
else
BASE="$BEFORE_SHA"
fi

if git diff --quiet "$BASE" "$GITHUB_SHA" -- \
src tests config examples composer.json testo.php psalm.xml \
rector.php .php-cs-fixer.php infection.json5 \
.github/workflows/build.yml; then
echo "run=false" >> "$GITHUB_OUTPUT"
else
echo "run=true" >> "$GITHUB_OUTPUT"
fi

build:
name: PHP ${{ matrix.php }}
needs: changes
if: ${{ !cancelled() && (needs.changes.result != 'success' || needs.changes.outputs.run == 'true') }}
runs-on: ubuntu-latest

strategy:
Expand Down Expand Up @@ -55,6 +97,8 @@ jobs:

prefer-lowest:
name: Prefer lowest
needs: changes
if: ${{ !cancelled() && (needs.changes.result != 'success' || needs.changes.outputs.run == 'true') }}
runs-on: ubuntu-latest

steps:
Expand Down Expand Up @@ -86,6 +130,8 @@ jobs:

coverage:
name: Coverage & Mutation
needs: changes
if: ${{ !cancelled() && (needs.changes.result != 'success' || needs.changes.outputs.run == 'true') }}
runs-on: ubuntu-latest

steps:
Expand Down Expand Up @@ -120,6 +166,8 @@ jobs:

compatibility:
name: Backward compatibility
needs: changes
if: ${{ !cancelled() && (needs.changes.result != 'success' || needs.changes.outputs.run == 'true') }}
runs-on: ubuntu-latest

steps:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
runs-on: ubuntu-latest
permissions:
# creating a Release object is a write to the repository
contents: write
contents: write # Needed to create the GitHub release

steps:
- name: Checkout
Expand Down
42 changes: 42 additions & 0 deletions .github/workflows/static-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,50 @@ concurrency:
cancel-in-progress: true

jobs:

changes:
name: Relevant changes
runs-on: ubuntu-latest

outputs:
run: ${{ steps.filter.outputs.run }}

steps:
- name: Checkout
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
with:
persist-credentials: false
fetch-depth: 0

- name: Detect relevant changes
id: filter
env:
EVENT_NAME: ${{ github.event_name }}
BEFORE_SHA: ${{ github.event.before }}
BASE_SHA: ${{ github.event.pull_request.base.sha }}
run: |
if [ "$EVENT_NAME" = "pull_request" ]; then
BASE="$BASE_SHA"
elif [ "$BEFORE_SHA" = "0000000000000000000000000000000000000000" ]; then
echo "run=true" >> "$GITHUB_OUTPUT"
exit 0
else
BASE="$BEFORE_SHA"
fi

if git diff --quiet "$BASE" "$GITHUB_SHA" -- \
src tests config examples composer.json testo.php psalm.xml \
rector.php .php-cs-fixer.php infection.json5 \
.github/workflows/static-analysis.yml; then
echo "run=false" >> "$GITHUB_OUTPUT"
else
echo "run=true" >> "$GITHUB_OUTPUT"
fi

psalm:
name: Psalm
needs: changes
if: ${{ !cancelled() && (needs.changes.result != 'success' || needs.changes.outputs.run == 'true') }}
runs-on: ubuntu-latest

steps:
Expand Down
38 changes: 38 additions & 0 deletions .github/workflows/zizmor.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: GitHub Actions security

on:
pull_request:
paths: &paths
- '.github/**/*.yml'
- '.github/**/*.yaml'
push:
branches:
- master
paths: *paths

permissions:
contents: read

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
zizmor:
name: zizmor
runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
with:
persist-credentials: false

- name: Audit GitHub Actions
uses: zizmorcore/zizmor-action@3dc1ecc9bcb9e94e9b2c709687979e1298497054 # v0.6.2
with:
advanced-security: false
annotations: true
online-audits: false
persona: auditor
version: 1.25.2
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# Changelog

## Unreleased

### Changed

- Add a `zizmor` GitHub Actions security audit workflow and skip heavy CI jobs on irrelevant changes via a path-aware gate.

## 1.1.0 — 2026-07-25

- Ship an AI agent skill (`resources/skills/rasuvaeff-specification/SKILL.md`
Expand Down
Loading