79209576

Date: 2024-11-21 03:25:04
Score: 1.5
Natty:
Report link

Quite late to the party, but what about merging the jobs and adding the condition to the step?

jobs:
  build-deploy:
    runs-on: ubuntu-latest
    steps:
      - name build
        run: echo "build"

      - name test
        if: ${{ github.ref_name == 'main' }}
        run: echo "build"

      - name deploy
        run: echo "deploy"
Reasons:
  • Has code block (-0.5):
  • Ends in question mark (2):
Posted by: Benoit