Skip to content

Commit

Permalink
Merge pull request #1542 from Automattic/add/npm-provenance
Browse files Browse the repository at this point in the history
chore: generate and verify provenance statements
  • Loading branch information
sjinks authored Nov 2, 2023
2 parents bcbc08b + 43d77cb commit d0d3c29
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 1 deletion.
20 changes: 20 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,26 @@ jobs:
- name: Run ${{ matrix.config.tool }}
run: npm run '${{ matrix.config.tool }}'

audit:
name: Verify signatures and provenance statements
runs-on: ubuntu-latest
steps:
- name: Check out the source code
uses: actions/checkout@v3

- name: Set up Node.js environment
uses: actions/setup-node@v3
with:
node-version: lts/*
cache: npm
cache-dependency-path: npm-shrinkwrap.json

- name: Install dependencies
run: npm ci

- name: Run audit
run: npm audit signatures

test:
name: Run tests
runs-on: ubuntu-latest
Expand Down
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -186,6 +186,7 @@
}
},
"publishConfig": {
"access": "public"
"access": "public",
"provenance": true
}
}

0 comments on commit d0d3c29

Please sign in to comment.