Skip to content

Commit

Permalink
ci: Only run mutants workflow under certain conditions (#2158)
Browse files Browse the repository at this point in the history
And simplify the per-step conditions accordingly.
  • Loading branch information
larseggert authored Oct 7, 2024
1 parent d6cc30e commit bd02153
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions .github/workflows/mutants.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ permissions:

jobs:
mutants:
if: github.event_name == 'pull_request' || github.event_name == 'schedule' || github.event_name == 'workflow_dispatch'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@d632683dd7b4114ad314bca15554477dd762a938 # v4.2.0
Expand Down Expand Up @@ -51,18 +52,16 @@ jobs:
echo 'TITLE=All Mutants' >> "$GITHUB_ENV"
- name: Post step summary
if: always()
run: |
{
echo "### $TITLE"
echo "See https://mutants.rs/using-results.html for more information."
echo '```'
sed 's/\x1b\[[0-9;]*[mGKHF]//g' results.txt
sed 's/\x1b\[[0-9;]*[mGKHF]//g' results.txt || true
echo '```'
} > "$GITHUB_STEP_SUMMARY"
- uses: actions/upload-artifact@50769540e7f4bd5e21e526ee35c689e35e0d6874 # v4.4.0
if: always()
with:
name: mutants.out
path: mutants.out

0 comments on commit bd02153

Please sign in to comment.