diff --git a/.gitignore b/.gitignore index cfbc04f98..24435f09e 100644 --- a/.gitignore +++ b/.gitignore @@ -24,4 +24,5 @@ test/nw/app.nw local.env .mason .eslintrc.js -setup.sh \ No newline at end of file +setup.sh +prebuilds \ No newline at end of file diff --git a/.travis.yml b/.travis.yml index 59b74d49e..6509738e9 100644 --- a/.travis.yml +++ b/.travis.yml @@ -60,17 +60,10 @@ matrix: apt: sources: [ 'ubuntu-toolchain-r-test','llvm-toolchain-precise-3.5', 'gcc-multilib', 'g++-multilib', 'libsqlite3-dev:i386' ] packages: [ 'clang-3.5'] - - os: linux - compiler: clang - env: NODE_VERSION="0.10" - addons: - apt: - sources: [ 'ubuntu-toolchain-r-test','llvm-toolchain-precise-3.5', 'gcc-multilib', 'g++-multilib', 'libsqlite3-dev:i386' ] - packages: [ 'clang-3.5'] # test building against external sqlite - os: linux compiler: clang - env: NODE_VERSION="0.10" EXTERNAL_SQLITE=true PUBLISHABLE=false + env: NODE_VERSION="8" EXTERNAL_SQLITE=true PUBLISHABLE=false addons: apt: sources: [ 'ubuntu-toolchain-r-test','llvm-toolchain-precise-3.5', 'gcc-multilib', 'g++-multilib', 'libsqlite3-dev:i386' ] @@ -97,15 +90,10 @@ matrix: - os: osx compiler: clang env: NODE_VERSION="4" # node abi 46 - - os: osx - compiler: clang - env: NODE_VERSION="0.10" # node abi 11 env: global: - JOBS: "8" - - secure: PifMOSnn+mWR1RUptXse+fLvWiTrzg0R/mazO7RWhXHWBKv0uAJ/qV3dI0GIRBLtjG10Iy+tT5RNh1TIbBzB9Y67wMcGvylUPG1+3EOKoBMEPnOD9AgCEQw4SOXfGPx0cq2N6ueSKieCgu1yKN9Wq7XCbE+zTk/DiRNIdLirVoo= - - secure: cc4esJY1vPXL31IeumAJoKWDDO2BTGFiltwfO1jbTbiV7QT911QUjTUasxXIVpOaHNCpxSTyevPwwTWfzt2EtF92Lli+qhQ2bbzMiDSBZstSrHdAe62Ai2M1oYYUwk/0cABB/2nO9uRyYwITCxpTSNzZBrYhn3C29WqBhPeVDmM= before_install: - export PUBLISHABLE=${PUBLISHABLE:-true} diff --git a/CHANGELOG.md b/CHANGELOG.md index f34606b2b..cb9328c8c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,11 @@ # Changelog +## 4.0.0 + + - Drop support for Node v0.10 and v.12 + - Upgrade to node-pre-gyp@0.9.0 + - Upgrade to nan@2.9.2 + ## 3.1.13 - Attempt to fix regression of #866 diff --git a/Makefile b/Makefile index 56fcb276a..1cd9b770a 100644 --- a/Makefile +++ b/Makefile @@ -33,13 +33,8 @@ rebuild: @make clean @make -ifndef only test: - @PATH="./node_modules/mocha/bin:${PATH}" && NODE_PATH="./lib:$(NODE_PATH)" mocha -R spec -else -test: - @PATH="./node_modules/mocha/bin:${PATH}" && NODE_PATH="./lib:$(NODE_PATH)" mocha -R spec test/${only}.test.js -endif + npm test check: test diff --git a/README.md b/README.md index 6bdf33bf7..04a1faf07 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,7 @@ Asynchronous, non-blocking [SQLite3](http://sqlite.org/) bindings for [Node.js]( ## Supported platforms -The `sqlite3` module works with Node.js v0.10.x, v0.12.x, v4.x, v5.x, v6.x and v7.x. +The `sqlite3` module works with Node.js v4.x, v5.x, v6.x and v7.x. Binaries for most Node versions and platforms are provided by default via [node-pre-gyp](https://github.com/mapbox/node-pre-gyp). diff --git a/appveyor.yml b/appveyor.yml index ce5c5808e..4ed6b2a62 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -1,17 +1,5 @@ environment: - node_pre_gyp_accessKeyId: - secure: 7DrSVc5eIGtmMcki5H+iRft+Tk3MJTwDBQEUuJHWaQ4= - node_pre_gyp_secretAccessKey: - secure: 1amwJJw9fu0j6dXnc5KsAQbSYf7Cjw/dapT6OZWABa6nc52grkKeLQ+DGaOfQz8i matrix: - - nodejs_version: 0.10 - platform: x86 - - nodejs_version: 0.10 - platform: x64 - - nodejs_version: 0.12 - platform: x86 - - nodejs_version: 0.12 - platform: x64 - nodejs_version: 4 platform: x64 - nodejs_version: 4 @@ -36,23 +24,6 @@ environment: platform: x64 - nodejs_version: 9 platform: x86 - # custom visual studio 2015 builds - - nodejs_version: 0.10.40 - platform: x86 - msvs_toolset: 14 - TOOLSET_ARGS: --dist-url=https://s3.amazonaws.com/mapbox/node-cpp11 --toolset=v140 - - nodejs_version: 0.10.40 - platform: x64 - msvs_toolset: 14 - TOOLSET_ARGS: --dist-url=https://s3.amazonaws.com/mapbox/node-cpp11 --toolset=v140 - - nodejs_version: 0.12.7 - platform: x86 - msvs_toolset: 14 - TOOLSET_ARGS: --dist-url=https://s3.amazonaws.com/mapbox/node-cpp11 --toolset=v140 - - nodejs_version: 0.12.7 - platform: x64 - msvs_toolset: 14 - TOOLSET_ARGS: --dist-url=https://s3.amazonaws.com/mapbox/node-cpp11 --toolset=v140 os: Visual Studio 2015 diff --git a/cloudformation/ci.template.js b/cloudformation/ci.template.js new file mode 100644 index 000000000..719e80071 --- /dev/null +++ b/cloudformation/ci.template.js @@ -0,0 +1,59 @@ +var cf = require('@mapbox/cloudfriend'); +var package_json = require('../package.json') + +module.exports = { + AWSTemplateFormatVersion: '2010-09-09', + Description: 'user for publishing to s3://mapbox-node-binary/' + package_json.name, + Resources: { + User: { + Type: 'AWS::IAM::User', + Properties: { + Policies: [ + { + PolicyName: 'list', + PolicyDocument: { + Statement: [ + { + Action: ['s3:ListBucket'], + Effect: 'Allow', + Resource: 'arn:aws:s3:::mapbox-node-binary', + Condition : { + StringLike : { + "s3:prefix": [ package_json.name + "/*"] + } + } + } + ] + } + }, + { + PolicyName: 'publish', + PolicyDocument: { + Statement: [ + { + Action: ['s3:DeleteObject', 's3:GetObject', 's3:GetObjectAcl', 's3:PutObject', 's3:PutObjectAcl'], + Effect: 'Allow', + Resource: 'arn:aws:s3:::mapbox-node-binary/' + package_json.name + '/*' + } + ] + } + } + ] + } + }, + AccessKey: { + Type: 'AWS::IAM::AccessKey', + Properties: { + UserName: cf.ref('User') + } + } + }, + Outputs: { + AccessKeyId: { + Value: cf.ref('AccessKey') + }, + SecretAccessKey: { + Value: cf.getAtt('AccessKey', 'SecretAccessKey') + } + } +}; diff --git a/package.json b/package.json index c583d3694..36dc611ed 100644 --- a/package.json +++ b/package.json @@ -1,8 +1,8 @@ { "name": "sqlite3", "description": "Asynchronous, non-blocking SQLite3 bindings", - "version": "3.1.13", - "homepage": "http://github.com/mapbox/node-sqlite3", + "version": "4.0.0", + "homepage": "http://github.com/theone74/node-sqlite3", "author": { "name": "MapBox", "url": "https://mapbox.com/" @@ -10,9 +10,9 @@ "binary": { "module_name": "node_sqlite3", "module_path": "./lib/binding/{node_abi}-{platform}-{arch}", - "host": "https://mapbox-node-binary.s3.amazonaws.com", - "remote_path": "./{name}/v{version}/{toolset}/", - "package_name": "{node_abi}-{platform}-{arch}.tar.gz" + "host": "https://github.com/theone74/node-sqlite3/releases/download/", + "remote_path": "v{version}", + "package_name": "{name}-v{version}-{node_abi}-{platform}-{arch}.tar.gz" }, "contributors": [ "Konstantin Käfer ", @@ -34,16 +34,17 @@ ], "repository": { "type": "git", - "url": "git://github.com/mapbox/node-sqlite3.git" + "url": "git://github.com/theone74/node-sqlite3.git" }, "dependencies": { - "nan": "~2.8.0", - "node-pre-gyp": "~0.6.38" + "nan": "~2.9.2", + "node-pre-gyp": "~0.9.0" }, "bundledDependencies": [ "node-pre-gyp" ], "devDependencies": { + "@mapbox/cloudfriend": "^1.9.0", "aws-sdk": "2.x", "eslint": "3.5.0", "mocha": "3.x"