Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prebuild and publish binaries #63

Merged
merged 9 commits into from Apr 22, 2020
Merged
Show file tree
Hide file tree
Changes from 6 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
31 changes: 29 additions & 2 deletions .travis.yml
Expand Up @@ -2,6 +2,8 @@ sudo: false

env:
- CXX=g++-4.9
- CXX=clang++

addons:
apt:
sources:
Expand All @@ -11,12 +13,37 @@ addons:

language: node_js

os:
- linux
- osx

osx_image: xcode10

node_js:
- "4"
- "6"
- "8"
- "9"
- "10"
- "12"

jobs:
exclude:
- os: osx
env: CXX=g++-4.9
- os: linux
env: CXX=clang++

install:
- npm install --build-from-source

after_success:
- npm install coveralls
- nyc report --reporter=text-lcov | ./node_modules/.bin/coveralls

deploy:
provider: script
script:
- npm run upload-posix
skip_cleanup: true
on:
tags: true
repo: node-ffi-napi/node-ffi-napi
9 changes: 7 additions & 2 deletions appveyor.yml
Expand Up @@ -5,9 +5,10 @@ environment:
# Test against these versions of Node.js and io.js
matrix:
# node.js
- nodejs_version: "6"
- nodejs_version: "8"
- nodejs_version: "9"
- nodejs_version: "10"
- nodejs_version: "12"

platform:
- x86
Expand All @@ -20,7 +21,7 @@ install:
- ps: Install-Product node $env:nodejs_version $env:platform
- node -p process.arch
- node -p process.version
- npm install
- npm install --build-from-source

# Post-install test scripts.
test_script:
Expand All @@ -35,3 +36,7 @@ build: off

# Set build version format here instead of in the admin panel.
version: "{build}"

deploy_script:
- IF "%APPVEYOR_REPO_TAG%" == "true" (npm run upload-windows)
- IF NOT "%APPVEYOR_REPO_TAG%" == "true" (echo 'Not tagged, skipping deploy')
9 changes: 7 additions & 2 deletions package.json
Expand Up @@ -30,17 +30,22 @@
"debug": "^3.1.0",
"get-uv-event-loop-napi-h": "^1.0.5",
"node-addon-api": "1.6.1",
"prebuild-install": "^5.3.3",
"ref-napi": "^1.4.0",
"ref-struct-di": "^1.1.0"
},
"devDependencies": {
"fs-extra": "^5.0.0",
"mocha": "^5.0.0",
"nyc": "^12.0.1",
"nyc": "^15.0.0",
"prebuild": "^10.0.0",
"ref-array-di": "^1.2.1"
},
"scripts": {
"test": "node-gyp rebuild --directory test && nyc mocha -gc --reporter spec"
"upload-posix": "prebuild -t $npm_config_node_version -u $PREBUILD_GITHUB_TOKEN --include-regex \"bindings\\.node$\"",
"upload-windows": "prebuild -t %npm_config_node_version% -u %PREBUILD_GITHUB_TOKEN% --include-regex \"bindings\\.node$\"",
"test": "node-gyp rebuild --directory test && nyc mocha -gc --reporter spec",
"install": "prebuild-install --verbose || node-gyp rebuild"
},
"repository": {
"type": "git",
Expand Down