Skip to content

Commit 347eb6f

Browse files
committed
Move to npm from yarn
1 parent bd59748 commit 347eb6f

9 files changed

+1586
-910
lines changed

.github/dependabot.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
version: 2
77
updates:
8-
- package-ecosystem: "yarn" # See documentation for possible values
8+
- package-ecosystem: "npm" # See documentation for possible values
99
directory: "/" # Location of package manifests
1010
schedule:
1111
interval: "weekly"

.github/workflows/ci.yml

+10-13
Original file line numberDiff line numberDiff line change
@@ -14,13 +14,10 @@ jobs:
1414
submodules: true
1515

1616
- name: Install dependencies
17-
run: yarn install --frozen-lockfile
17+
run: npm ci
1818

1919
- name: Lint
20-
run: yarn lint
21-
22-
- name: Audit
23-
run: yarn audit
20+
run: npm run lint
2421

2522
test:
2623
strategy:
@@ -40,14 +37,14 @@ jobs:
4037
- name: Use Node.js ${{ matrix.node-version }}
4138
uses: actions/setup-node@v4
4239
with:
43-
cache: yarn
40+
cache: npm
4441
node-version: ${{ matrix.node-version }}
4542

4643
- name: Install dependencies
47-
run: yarn install --frozen-lockfile
44+
run: npm ci
4845

4946
- name: Run tests
50-
run: yarn test
47+
run: npm test
5148

5249
test-alpine:
5350
strategy:
@@ -70,10 +67,10 @@ jobs:
7067
submodules: true
7168

7269
- name: Install dependencies
73-
run: yarn install --frozen-lockfile
70+
run: npm ci
7471

7572
- name: Run tests
76-
run: yarn test
73+
run: npm test
7774

7875
test-freebsd:
7976
strategy:
@@ -92,8 +89,8 @@ jobs:
9289
- uses: vmactions/freebsd-vm@v1
9390
with:
9491
prepare: |
95-
pkg install -y gmake python3 yarn-node${{ matrix.node-version }}
92+
pkg install -y gmake python3 npm-node${{ matrix.node-version }}
9693
run: |
97-
yarn install
98-
yarn test
94+
npm ci
95+
npm test
9996
sync: sshfs

.github/workflows/release.yml

+14-14
Original file line numberDiff line numberDiff line change
@@ -46,14 +46,14 @@ jobs:
4646
- name: Use Node.js 20
4747
uses: actions/setup-node@v4
4848
with:
49-
cache: yarn
49+
cache: npm
5050
node-version: 20
5151

5252
- name: Install dependencies
53-
run: yarn install --frozen-lockfile --ignore-scripts
53+
run: npm ci
5454

5555
- name: Prebuild
56-
run: yarn build
56+
run: npm run build
5757

5858
- name: Upload artifacts
5959
uses: actions/upload-artifact@v4
@@ -78,10 +78,10 @@ jobs:
7878
submodules: true
7979

8080
- name: Install dependencies
81-
run: yarn install --frozen-lockfile --ignore-scripts
81+
run: npm ci
8282

8383
- name: Prebuild
84-
run: yarn build
84+
run: npm run build
8585

8686
- name: Upload artifacts
8787
uses: actions/upload-artifact@v4
@@ -106,10 +106,10 @@ jobs:
106106
submodules: true
107107

108108
- name: Install dependencies
109-
run: yarn install --frozen-lockfile --ignore-scripts
109+
run: npm ci
110110

111111
- name: Prebuild
112-
run: yarn build
112+
run: npm run build
113113

114114
- name: Upload artifacts
115115
uses: actions/upload-artifact@v4
@@ -135,10 +135,10 @@ jobs:
135135
dockerRunArgs: --volume "${PWD}:/repo" --workdir /repo
136136
install: |
137137
apk add --update make g++ python3
138-
apk add --no-cache --repository https://dl-cdn.alpinelinux.org/alpine/v3.19/main/ nodejs~=20 yarn
138+
apk add --no-cache --repository https://dl-cdn.alpinelinux.org/alpine/v3.19/main/ nodejs~=20 npm
139139
run: |
140-
yarn install --frozen-lockfile --ignore-scripts
141-
yarn build
140+
npm ci
141+
npm run build
142142
143143
- name: Upload artifacts
144144
uses: actions/upload-artifact@v4
@@ -160,10 +160,10 @@ jobs:
160160
uses: vmactions/freebsd-vm@v1
161161
with:
162162
prepare: |
163-
pkg install -y gmake python3 yarn-node20
163+
pkg install -y gmake python3 npm-node20
164164
run: |
165-
yarn install --frozen-lockfile --ignore-scripts
166-
yarn build
165+
npm ci
166+
npm run build
167167
sync: sshfs
168168

169169
- name: Upload artifacts
@@ -199,7 +199,7 @@ jobs:
199199
run: |
200200
git config --global user.name 'github-actions[bot]'
201201
git config --global user.email 'github-actions[bot]@users.noreply.github.com'
202-
yarn publish --tag ${{ inputs.npm-tag }} --new-version $(echo $VERSION | sed 's/^v//')
202+
npm publish --tag ${{ inputs.npm-tag }} --new-version $(echo $VERSION | sed 's/^v//')
203203
if: ${{ !env.ACT }}
204204
env:
205205
NPM_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

.gitignore

-2
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,6 @@
33
logs
44
*.log
55
npm-debug.log*
6-
yarn-debug.log*
7-
yarn-error.log*
86

97
# Coverage directory used by tools like istanbul
108
coverage

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ you'll need to specify that in the command.
139139
2. Ignore `node-argon2` install script and build manually.
140140
```bash
141141
$ npm install argon2 --ignore-scripts
142-
$ npx @mapbox/node-pre-gyp rebuild -C ./node_modules/argon2
142+
$ npx node-gyp rebuild -C ./node_modules/argon2
143143
```
144144
</details>
145145

binding.gyp

+1-1
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@
5858
"sources": [
5959
"argon2_node.cpp"
6060
],
61-
"cflags_cc+": ["-Wall", "-Wextra", "-Wconversion", "-Wformat", "-Wnon-virtual-dtor", "-pedantic", "-Werror"],
61+
"cflags_cc+": ["-Wall", "-Wextra", "-Wformat", "-Wnon-virtual-dtor", "-pedantic", "-Werror"],
6262
"cflags_cc!": ["-fno-exceptions"],
6363
"include_dirs": ["<!(node -p \"require('node-addon-api').include_dir\")"],
6464
"dependencies": ["libargon2"],

0 commit comments

Comments
 (0)