Skip to content

Commit

Permalink
fix: update CI and example dependencies (#3)
Browse files Browse the repository at this point in the history
fix: update CI
  • Loading branch information
zainulbr committed Oct 29, 2020
1 parent 03bb4a3 commit 738c5b0
Show file tree
Hide file tree
Showing 6 changed files with 375 additions and 379 deletions.
32 changes: 14 additions & 18 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,38 +11,34 @@ jobs:
include:
- &test-latest
stage: Webpack latest
nodejs: 6
nodejs: 12
env: WEBPACK_VERSION=latest JOB_PART=test
script: npm run travis:$JOB_PART
script: yarn travis:$JOB_PART
- <<: *test-latest
nodejs: 4.3
env: WEBPACK_VERSION=latest JOB_PART=test
script: npm run travis:$JOB_PART
- <<: *test-latest
node_js: 8
node_js: 12
env: WEBPACK_VERSION=latest JOB_PART=lint
script: npm run travis:$JOB_PART
script: yarn travis:$JOB_PART
- <<: *test-latest
node_js: 8
node_js: 12
env: WEBPACK_VERSION=latest JOB_PART=coverage
script: npm run travis:$JOB_PART
script: yarn travis:$JOB_PART
after_success: 'bash <(curl -s https://codecov.io/bash)'
- stage: Webpack canary
before_script: npm i --no-save git://github.com/webpack/webpack.git#master
script: npm run travis:$JOB_PART
node_js: 8
env: WEBPACK_VERSION=canary JOB_PART=test
# - stage: Webpack canary
# before_script: npm i --no-save git://github.com/webpack/webpack.git#master
# script: yarn travis:$JOB_PART
# node_js: 12
# env: WEBPACK_VERSION=canary JOB_PART=test
before_install:
- 'if [[ `npm -v` != 5* ]]; then npm i -g npm@^5.0.0; fi'
- 'if [[ `npm -v` != 6* ]]; then npm i -g npm@^6.14.1; fi'
- nvm --version
- node --version
- npm --version
before_script:
- |-
if [ "$WEBPACK_VERSION" ]; then
npm i --no-save webpack@$WEBPACK_VERSION
yarn --no-save webpack@$WEBPACK_VERSION
fi
script:
- 'npm run travis:$JOB_PART'
- 'yarn travis:$JOB_PART'
after_success:
- 'bash <(curl -s https://codecov.io/bash)'
10 changes: 2 additions & 8 deletions appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,8 @@ init:
- git config --global core.autocrlf input
environment:
matrix:
- nodejs_version: '8'
webpack_version: 2.6.0
job_part: test
- nodejs_version: '6'
webpack_version: 2.6.0
job_part: test
- nodejs_version: '4.3'
webpack_version: 2.6.0
- nodejs_version: '12'
webpack_version: 5.3.1
job_part: test
build: 'off'
matrix:
Expand Down
6 changes: 3 additions & 3 deletions example/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@
"build": "webpack"
},
"devDependencies": {
"webpack": "^5.2.0",
"webpack-cli": "^4.1.0",
"@zainulbr/i18n-webpack-plugin":"2.0.1"
"@zainulbr/i18n-webpack-plugin": "^2.0.1",
"webpack": "^5.3.1",
"webpack-cli": "^4.1.0"
}
}
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
"test:watch": "jest --watch",
"test:coverage": "jest --collectCoverageFrom='src/**/*.js' --coverage",
"travis:coverage": "npm run test:coverage -- --runInBand",
"travis:lint": "npm run lint && npm run security",
"travis:lint": "npm run lint",
"travis:test": "npm run test -- --runInBand",
"webpack-defaults": "webpack-defaults"
},
Expand All @@ -47,15 +47,15 @@
"babel-polyfill": "^6.26.0",
"cross-env": "^7.0.2",
"del-cli": "^3.0.1",
"eslint": "^7.11.0",
"eslint": "^7.12.1",
"eslint-config-webpack": "^1.2.5",
"eslint-plugin-import": "^2.22.1",
"jest": "^26.6.1",
"lint-staged": "^10.4.2",
"lint-staged": "^10.5.0",
"nsp": "^3.2.1",
"pre-commit": "^1.2.2",
"standard-version": "^9.0.0",
"webpack": "^5.2.0",
"webpack": "^5.3.1",
"webpack-defaults": "^4.0.0"
},
"peerDependencies": {
Expand Down
2 changes: 1 addition & 1 deletion src/MakeLocalizeFunction.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ function byString(plocalization, nestedKey) {
for (let i = 0, { length } = keys; i < length; ++i) {
const key = keys[i];

if (!(key in localization)) { return undefined; }
if (!(key in localization)) { return; }

localization = localization[key];
}
Expand Down

0 comments on commit 738c5b0

Please sign in to comment.