danger / danger-js

⚠️ Stop saying "you forgot to …" in code review
http://danger.systems/js/
MIT License
5.29k stars 368 forks source link

[Feature] Provide some messaging if you are not on pull_request for GitHUb Actions CI #1438

Closed orta closed 7 months ago

orta commented 7 months ago

Describe the bug

name: CI
on: push
jobs:
  test:
    name: Lint, typecheck & test
    runs-on: ubuntu-latest

    steps:
      - name: Danger
        run: yarn danger ci --verbose
        env:
          DEBUG: danger:*
          DANGER_GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }}

Does not have danger.github.pr because it is not a PR run - however, because Danger can run on any GitHub workflow then things are going to be real surprising when it doesn't work.