4
0

codeql-analysis.yml 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. name: "CodeQL"
  2. permissions: read-all
  3. on:
  4. push:
  5. branches: [ main ]
  6. paths:
  7. - '**.js'
  8. - '**.go'
  9. - '!**_test.go'
  10. - '.github/workflows/codeql-analysis.yml'
  11. pull_request:
  12. # The branches below must be a subset of the branches above
  13. branches: [ main ]
  14. paths:
  15. - '**.js'
  16. - '**.go'
  17. - '!**_test.go'
  18. - '.github/workflows/codeql-analysis.yml'
  19. schedule:
  20. - cron: '45 22 * * 3'
  21. workflow_dispatch:
  22. jobs:
  23. analyze:
  24. name: Analyze (${{ matrix.language }})
  25. runs-on: ubuntu-latest
  26. permissions:
  27. actions: read
  28. contents: read
  29. security-events: write
  30. strategy:
  31. fail-fast: false
  32. matrix:
  33. language: [ 'go', 'javascript' ]
  34. steps:
  35. - name: Checkout repository
  36. uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
  37. - uses: actions/setup-go@924ae3a1cded613372ab5595356fb5720e22ba16 # v6.5.0
  38. if: matrix.language == 'go'
  39. with:
  40. go-version: stable
  41. - name: Initialize CodeQL
  42. uses: github/codeql-action/init@8aad20d150bbac5944a9f9d289da16a4b0d87c1e # v4.36.2
  43. with:
  44. languages: ${{ matrix.language }}
  45. - name: Autobuild
  46. uses: github/codeql-action/autobuild@8aad20d150bbac5944a9f9d289da16a4b0d87c1e # v4.36.2
  47. - name: Perform CodeQL Analysis
  48. uses: github/codeql-action/analyze@8aad20d150bbac5944a9f9d289da16a4b0d87c1e # v4.36.2
  49. with:
  50. category: "/language:${{ matrix.language }}"