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
9 changes: 4 additions & 5 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -136,8 +136,8 @@ jobs:
- name: Upload artifact
uses: actions/upload-artifact@v2
with:
name: bindings-musl
path: packages/*/*.musl.node
name: bindings-linux-musl
path: packages/**/*.node

test_binding:
name: Test bindings on ${{ matrix.os }} - node@${{ matrix.node }}
Expand Down Expand Up @@ -195,7 +195,6 @@ jobs:
test_musl_binding:
name: Test bindings on alpine - node@${{ matrix.node }}
needs:
- lint_and_build
- build_musl
strategy:
fail-fast: false
Expand All @@ -209,14 +208,14 @@ jobs:
- name: Download artifacts
uses: actions/download-artifact@v2
with:
name: bindings-musl
name: bindings-linux-musl
path: artifacts

- name: Move artifacts
run: node scripts/mv-artifacts.js
shell: bash
env:
MOVE_TARGET: musl
MOVE_TARGET: linux-musl

- name: List packages
run: ls -R packages
Expand Down
16 changes: 8 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,30 +20,30 @@
"typecheck": "tsc -b tsconfig.project.json -verbose"
},
"devDependencies": {
"@octokit/rest": "^18.0.0",
"@typescript-eslint/eslint-plugin": "^3.6.1",
"@typescript-eslint/parser": "^3.6.1",
"ava": "^3.10.1",
"@octokit/rest": "^18.0.3",
"@typescript-eslint/eslint-plugin": "^3.9.1",
"@typescript-eslint/parser": "^3.9.1",
"ava": "^3.11.1",
"benchmark": "^2.1.4",
"chalk": "^4.1.0",
"codecov": "^3.7.0",
"codecov": "^3.7.2",
"cross-env": "^7.0.2",
"eslint": "^7.4.0",
"eslint": "^7.7.0",
"eslint-config-prettier": "^6.11.0",
"eslint-plugin-import": "^2.22.0",
"eslint-plugin-prettier": "^3.1.4",
"eslint-plugin-sonarjs": "^0.5.0",
"husky": "^4.2.5",
"lerna": "^3.22.1",
"lint-staged": "^10.2.11",
"napi-rs": "^0.2.4",
"napi-rs": "^0.2.6",
"npm-run-all": "^4.1.5",
"nyc": "^15.1.0",
"prettier": "^2.0.5",
"putasset": "^5.0.3",
"ts-node": "^8.10.2",
"tsconfig-paths": "^3.9.0",
"typescript": "^3.9.6"
"typescript": "^4.0.2"
},
"ava": {
"extensions": ["ts"],
Expand Down
4 changes: 2 additions & 2 deletions packages/bcrypt/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@
},
"scripts": {
"bench": "cross-env NODE_ENV=production node benchmark/bcrypt.js",
"build": "napi --release ./bcrypt",
"build:debug": "napi ./bcrypt"
"build": "napi build --platform --release ./bcrypt",
"build:debug": "napi build --platform ./bcrypt"
},
"bugs": {
"url": "https://github.com/napi-rs/node-rs/issues"
Expand Down
4 changes: 2 additions & 2 deletions packages/crc32/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@
},
"scripts": {
"bench": "cross-env NODE_ENV=production node benchmark/crc32.js",
"build": "napi --release ./crc32",
"build:debug": "napi ./crc32"
"build": "napi build --platform --release ./crc32",
"build:debug": "napi build --platform ./crc32"
},
"bugs": {
"url": "https://github.com/napi-rs/node-rs/issues"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
"author": "LongYinan <lynweklm@gmail.com>",
"homepage": "https://github.com/napi-rs/node-rs",
"license": "MIT",
"main": "deno-lint.musl.node",
"files": ["deno-lint.musl.node"],
"main": "deno-lint.linux-musl.node",
"files": ["deno-lint.linux-musl.node"],
"os": ["linux"],
"cpu": ["x64"],
"engines": {
Expand Down
9 changes: 7 additions & 2 deletions packages/deno-lint/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@
},
"scripts": {
"bench": "cross-env NODE_ENV=production node benchmark/lint.js",
"build": "napi --release ./deno-lint",
"build:debug": "napi ./deno-lint",
"build": "napi build --platform --release ./deno-lint",
"build:debug": "napi build --platform ./deno-lint",
"prepublishOnly": "node ./publish.js",
"version": "node ./version.js"
},
Expand All @@ -41,5 +41,10 @@
},
"devDependencies": {
"@types/webpack": "^4.41.21"
},
"optionalDependencies": {
"@node-rs/deno-lint-win32": "^0.1.0",
"@node-rs/deno-lint-darwin": "^0.1.0",
"@node-rs/deno-lint-linux": "^0.1.0"
}
}
2 changes: 1 addition & 1 deletion packages/deno-lint/publish.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ updatePackageJson(path.join(__dirname, 'package.json'), {
}, {}),
})

for (const name of [...platforms, 'musl']) {
for (const name of [...platforms, 'linux-musl']) {
const pkgDir = path.join(__dirname, 'npm', name)
const filename = `deno-lint.${name}.node`
const bindingFile = fs.readFileSync(path.join(__dirname, filename))
Expand Down
2 changes: 1 addition & 1 deletion packages/deno-lint/version.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ const { version } = require('./package.json')
const platforms = require('./platforms')
const updatePackageJson = require('./update-package')

for (const name of [...platforms, 'musl']) {
for (const name of [...platforms, 'linux-musl']) {
const pkgDir = path.join(__dirname, 'npm', name)
updatePackageJson(path.join(pkgDir, 'package.json'), {
version,
Expand Down
2 changes: 1 addition & 1 deletion packages/helper/src/loader.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export function loadBinding(dirname: string, filename = 'index') {
try {
return require(bindingFilePath)
} catch {
return require(join(dirname, `${filename}.musl.node`))
return require(join(dirname, `${filename}.linux-musl.node`))
}
}

Expand Down
4 changes: 2 additions & 2 deletions packages/jieba/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@
},
"scripts": {
"bench": "cross-env NODE_ENV=production node benchmark/jieba.js",
"build": "napi --release ./jieba",
"build:debug": "napi ./jieba"
"build": "napi build --platform --release ./jieba",
"build:debug": "napi build --platform ./jieba"
},
"bugs": {
"url": "https://github.com/napi-rs/node-rs/issues"
Expand Down
2 changes: 1 addition & 1 deletion scripts/platforms.js
Original file line number Diff line number Diff line change
@@ -1 +1 @@
module.exports = ['linux', 'musl', 'darwin', 'win32']
module.exports = ['linux', 'linux-musl', 'darwin', 'win32']
Loading