Assign OSV IDs #16837
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Assign OSV IDs | |
on: | |
push: | |
branches: | |
- main | |
schedule: | |
- cron: '7 * * * *' # Once an hour | |
workflow_dispatch: | |
permissions: read-all | |
jobs: | |
assign-ids: | |
name: Assign IDs | |
continue-on-error: false | |
runs-on: ubuntu-latest | |
permissions: | |
actions: read | |
contents: write | |
steps: | |
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
with: | |
token: ${{ secrets.GH_TOKEN }} | |
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a # v5.2.0 | |
with: | |
go-version: "1.21" | |
- name: Preprocess reports | |
run: make preprocess | |
- name: Assign IDs | |
run: | | |
go install github.com/google/osv/vulnfeeds/cmd/ids@latest | |
ids -dir=./osv/malicious -prefix MAL -format json | |
env: | |
GONOPROXY: github.com/google/osv | |
- name: Prepare commit | |
run: | | |
git config user.name github-actions | |
git config user.email [email protected] | |
git add . | |
- name: Commit report changes | |
run: git diff --cached --quiet || git commit -m 'Assign IDs' | |
- name: Push commit | |
run: git push |