Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,7 @@ jobs:
name: Publish release
permissions:
contents: write
id-token: write
uses: ./.github/workflows/publish-release.yml
secrets:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
Expand Down
13 changes: 10 additions & 3 deletions .github/workflows/publish-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ on:
workflow_call:
secrets:
NPM_TOKEN:
required: true
required: false
SLACK_WEBHOOK_URL:
required: true

Expand Down Expand Up @@ -47,7 +47,7 @@ jobs:
with:
name: publish-release-artifacts-${{ github.sha }}
- name: Dry Run Publish
uses: MetaMask/action-npm-publish@v5
uses: MetaMask/action-npm-publish@18df42148c35aabb98e00f9fda127d421af141df # v6

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No need to pin these. You can add a Zizmor config like the one in the module-template to remove these errors.

with:
slack-webhook-url: ${{ secrets.SLACK_WEBHOOK_URL }}

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
slack-webhook-url: ${{ secrets.SLACK_WEBHOOK_URL }}
dry-run: true
slack-webhook-url: ${{ secrets.SLACK_WEBHOOK_URL }}

subteam: S042S7RE4AE
Expand All @@ -58,6 +58,9 @@ jobs:
needs: publish-npm-dry-run
runs-on: ubuntu-latest
environment: npm-publish
permissions:
contents: read
id-token: write
steps:
- name: Checkout and setup environment
uses: MetaMask/action-checkout-and-setup@v2
Expand All @@ -69,8 +72,12 @@ jobs:
with:
name: publish-release-artifacts-${{ github.sha }}
- name: Publish
uses: MetaMask/action-npm-publish@v5
uses: MetaMask/action-npm-publish@18df42148c35aabb98e00f9fda127d421af141df # v6
with:

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We added a dry-run option later. Not required now, but recommended. Will probably be required in the next major version.

Suggested change
with:
with:
dry-run: false

# This `NPM_TOKEN` is only needed to publish a package for the first
# time. Look in the repository settings under "Environments", and set
# this token in the `npm-publish` environment, then delete it after
# the initial OIDC publish.
npm-token: ${{ secrets.NPM_TOKEN }}
env:
SKIP_PREPACK: true
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@
"@playwright/test": "^1.49.0",
"playwright": "^1.49.0"
},
"packageManager": "yarn@4.11.0",
"packageManager": "yarn@4.16.0",

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not a strict requirement but we recommend pinning this to a checksum:

Suggested change
"packageManager": "yarn@4.16.0",
"packageManager": "yarn@4.16.0+sha256.ba05224324578801b9cc98170d64aa50b9a36733b440fb0942306da3fbbdc7d1",

"engines": {
"node": "^20 || ^22 || >=24"
},
Expand Down
2 changes: 1 addition & 1 deletion yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# Manual changes might be lost - proceed with caution!

__metadata:
version: 8
version: 10
cacheKey: 10

"@andrewbranch/untar.js@npm:^1.0.3":
Expand Down
Loading