Skip to content
Merged
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 @@ -86,6 +86,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
21 changes: 15 additions & 6 deletions .github/workflows/publish-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,15 @@ on:
workflow_call:
secrets:
NPM_TOKEN:
required: true
required: false
SLACK_WEBHOOK_URL:
required: true
PUBLISH_DOCS_TOKEN:
required: true

permissions:
contents: read

jobs:
publish-release:
permissions:
Expand Down Expand Up @@ -48,8 +52,7 @@ jobs:
with:
name: publish-release-artifacts-${{ github.sha }}
- name: Dry Run Publish
# omit npm-token token to perform dry run publish
uses: MetaMask/action-npm-publish@v5
uses: MetaMask/action-npm-publish@v6
with:
slack-webhook-url: ${{ secrets.SLACK_WEBHOOK_URL }}
subteam: S042S7RE4AE # @metamask-npm-publishers
Expand All @@ -60,6 +63,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@v1
Expand All @@ -71,10 +77,13 @@ jobs:
with:
name: publish-release-artifacts-${{ github.sha }}
- name: Publish
uses: MetaMask/action-npm-publish@v5
uses: MetaMask/action-npm-publish@v6
with:
# This `NPM_TOKEN` needs to be manually set per-repository.
# Look in the repository settings under "Environments", and set this token in the `npm-publish` environment.
# This `NPM_TOKEN` needs to be manually set to publish a package for
# the first time only.
# Look in the repository settings under "Environments", and set this
# token in the `npm-publish` environment, and delete it after the
# initial publish.
npm-token: ${{ secrets.NPM_TOKEN }}
env:
SKIP_PREPACK: true
Expand Down
18 changes: 17 additions & 1 deletion .yarnrc.yml
Original file line number Diff line number Diff line change
@@ -1,17 +1,33 @@
# Allowlist for Git repositories that can be used as dependencies. We set it to
# an empty array to disallow all Git dependencies, as we don't use any and they
# can be a security risk.
approvedGitRepositories: []

compressionLevel: mixed

enableGlobalCache: false

enableScripts: false

enableTelemetry: 0
enableTelemetry: false

logFilters:
- code: YN0004
level: discard

nodeLinker: node-modules

# Configure the NPM minimal age gate to 3 days, meaning packages must be at
# least 3 days old to be installed.
npmMinimalAgeGate: 4320 # 3 days (in minutes)

# Override the minimal age gate, allowing certain packages to be installed
# regardless of their publish age.
npmPreapprovedPackages:
- '@metamask/*'
- '@metamask-previews/*'
- '@lavamoat/*'

plugins:
- path: .yarn/plugins/@yarnpkg/plugin-allow-scripts.cjs
spec: "https://raw.githubusercontent.com/LavaMoat/LavaMoat/main/packages/yarn-plugin-allow-scripts/bundles/@yarnpkg/plugin-allow-scripts.js"
9 changes: 6 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,9 @@
"test": "jest && jest-it-up && attw --pack",
"test:watch": "jest --watch"
},
"resolutions": {
"fflate": "0.8.2"
},
"dependencies": {
"@metamask/scure-bip39": "^2.1.1",
"@metamask/utils": "^11.0.1",
Expand All @@ -70,7 +73,6 @@
"eslint": "^9.11.0",
"eslint-config-prettier": "^9.1.0",
"eslint-import-resolver-typescript": "^3.6.3",
"eslint-plugin-import": "~2.26.0",
"eslint-plugin-import-x": "^4.3.0",
"eslint-plugin-jest": "^28.8.3",
"eslint-plugin-jsdoc": "^50.2.4",
Expand All @@ -87,7 +89,7 @@
"typescript": "~5.4.5",
"typescript-eslint": "^8.6.0"
},
"packageManager": "yarn@4.1.1",
"packageManager": "yarn@4.16.0",
"engines": {
"node": "^18.20 || ^20.17 || >=22"
},
Expand All @@ -97,7 +99,8 @@
},
"lavamoat": {
"allowScripts": {
"@lavamoat/preinstall-always-fail": false
"@lavamoat/preinstall-always-fail": false,
"eslint-plugin-import-x>unrs-resolver": false
}
}
}
2 changes: 1 addition & 1 deletion test/vectors.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ import { hexToBytes } from '@metamask/utils';
// eslint-disable-next-line n/no-unsupported-features/node-builtins
import { webcrypto } from 'crypto';

import derivationVectors from './vectors/derivation.json';
import type { SLIP10Node, SLIP10PathTuple } from '../src';
import { secp256k1 } from '../src';
import derivationVectors from './vectors/derivation.json';
import type { Curve } from '../src/curves';
import { ed25519Bip32, ed25519 } from '../src/curves';
import {
Expand Down
Loading
Loading