Skip to content

Commit

Permalink
Updated node and service versions
Browse files Browse the repository at this point in the history
  • Loading branch information
dolezel committed Jun 5, 2018
1 parent 176e576 commit d246443
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 18 deletions.
2 changes: 1 addition & 1 deletion .babelrc
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"env",
{
"targets": {
"node": 4
"node": 6
}
}
],
Expand Down
14 changes: 10 additions & 4 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,22 +2,28 @@ version: 2
jobs:
build:
docker:
- image: circleci/node:4.8.2
- image: circleci/node:6
environment:
- NODE_ENV=test
- DATABASE_URL_POSTGRES=postgres://ubuntu@localhost:5432/circle_test
- DATABASE_URL_COCKROACH=postgresql://root@localhost:26257/circle_test
- image: postgres:9.6
- image: postgres:10.4-alpine
environment:
- POSTGRES_USER=ubuntu
- POSTGRES_DB=circle_test
- image: cockroachdb/cockroach:v1.1.6
- image: cockroachdb/cockroach:v1.1.8
command: ['start', '--insecure', '--host=localhost']
steps:
- checkout
- run:
name: update-npm
command: 'sudo npm install -g [email protected]'
command: |
mkdir ~/.npm-global
npm config set prefix '~/.npm-global'
echo 'export NPM_CONFIG_PREFIX=~/.npm-global' >> $BASH_ENV
echo 'export PATH=~/.npm-global/bin:$PATH' >> $BASH_ENV
source $BASH_ENV
npm install -g [email protected]
- restore_cache:
key: dependency-cache-{{ checksum "package.json" }}
- run:
Expand Down
27 changes: 14 additions & 13 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
"api"
],
"engines": {
"node": ">=4.0.0"
"node": ">=6.0.0"
},
"bugs": {
"url": "https://github.com/salsita/node-pg-migrate/issues"
Expand Down Expand Up @@ -84,22 +84,23 @@
"compile": "babel lib/ -d dist/ && cp lib/migration-template.* dist/",
"test:mocha": "cross-env NODE_ENV=test mocha --opts ./mocha.opts test",
"migrate": "babel-node bin/node-pg-migrate",
"migrate:postgres":
"DATABASE_URL=$DATABASE_URL_POSTGRES npm run migrate -- -m test/migrations",
"migrate:cockroach":
"DATABASE_URL=$DATABASE_URL_COCKROACH npm run migrate -- -m test/cockroach -s '' --migrations-schema circle_test --no-lock",
"test:postgres":
"npm run migrate:postgres up && npm run migrate:postgres down 0 -- --timestamps",
"test:cockroach":
"npm run migrate:cockroach up && npm run migrate:cockroach down 0 -- --timestamp",
"test":
"npm run test:mocha && npm run test:postgres && npm run test:cockroach",
"migrate:postgres": "DATABASE_URL=$DATABASE_URL_POSTGRES npm run migrate -- -m test/migrations",
"migrate:cockroach": "DATABASE_URL=$DATABASE_URL_COCKROACH npm run migrate -- -m test/cockroach -s '' --migrations-schema circle_test --no-lock",
"test:postgres": "npm run migrate:postgres up && npm run migrate:postgres down 0 -- --timestamps",
"test:cockroach": "npm run migrate:cockroach up && npm run migrate:cockroach down 0 -- --timestamp",
"test": "npm run test:mocha && npm run test:postgres && npm run test:cockroach",
"lint": "eslint -c eslintrc.js . bin/*",
"lintfix": "npm run lint -- --fix",
"prepare": "npm run compile"
},
"lint-staged": {
"*.js": ["npm run lintfix", "git add"],
"*.{json,md}": ["prettier --write", "git add"]
"*.js": [
"npm run lintfix",
"git add"
],
"*.{json,md}": [
"prettier --write",
"git add"
]
}
}

0 comments on commit d246443

Please sign in to comment.