From 076fc589fdcf942e013d59a833fc455759918ada Mon Sep 17 00:00:00 2001 From: Joshua Wiens Date: Wed, 14 Jun 2017 11:58:11 -0500 Subject: [PATCH 1/8] chore: Update to defaults travis config - Enables "canary" testing of webpack via stages --- .travis.yml | 53 ++++++++++++++++++++++++++++++++++++++++++++++------- 1 file changed, 46 insertions(+), 7 deletions(-) diff --git a/.travis.yml b/.travis.yml index 20b24a0d..26f89cae 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,10 +1,49 @@ sudo: false +dist: trusty language: node_js -node_js: - - "7" - - "6" - - "4" - +branches: + only: + - master + - feature/webpack3 +jobs: + fast_finish: true + allow_failures: + - env: WEBPACK_VERSION=canary + include: + - &test-latest + stage: Webpack latest + nodejs: 6 + env: WEBPACK_VERSION=latest JOB_PART=test + script: npm run 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 + env: WEBPACK_VERSION=latest JOB_PART=lint + script: npm run travis:$JOB_PART + - <<: *test-latest + node_js: 8 + env: WEBPACK_VERSION=latest JOB_PART=coverage + script: npm run 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 +before_install: + - 'if [[ `npm -v` != 5* ]]; then npm i -g npm@^5.0.0; fi' + - nvm --version + - node --version + - npm --version +before_script: + - |- + if [ "$WEBPACK_VERSION" ]; then + npm i --no-save webpack@$WEBPACK_VERSION + fi +script: + - 'npm run travis:$JOB_PART' after_success: - - npm install coveralls - - npm run coverage && cat ./coverage/lcov.info | ./node_modules/coveralls/bin/coveralls.js && rm -rf ./coverage + - 'bash <(curl -s https://codecov.io/bash)' From 96c6d63800a3198fccb6ed91d6214330d47c0652 Mon Sep 17 00:00:00 2001 From: Joshua Wiens Date: Wed, 14 Jun 2017 11:58:37 -0500 Subject: [PATCH 2/8] chore: Update to defaults appveyor build --- appveyor.yml | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/appveyor.yml b/appveyor.yml index 98d6c1eb..d257e41d 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -1,28 +1,28 @@ -# appveyor file -# http://www.appveyor.com/docs/appveyor-yml - +branches: + only: + - master init: - git config --global core.autocrlf input - -# what combinations to test environment: matrix: - - nodejs_version: 7 + - nodejs_version: '8' + webpack_version: latest job_part: test - - nodejs_version: 6 + - nodejs_version: '6' + webpack_version: latest job_part: test - - nodejs_version: 4 + - nodejs_version: '4' + webpack_version: latest job_part: test - +build: 'off' +matrix: + fast_finish: true install: - ps: Install-Product node $env:nodejs_version x64 + - npm i -g npm@^5.0.0 - npm install - -build: off - -matrix: - fast_finish: true - +before_test: + - cmd: npm i --no-save webpack@%webpack_version% test_script: - node --version - npm --version From 37da1d1fb6a8044912970d72ef704369252498be Mon Sep 17 00:00:00 2001 From: Joshua Wiens Date: Wed, 14 Jun 2017 11:59:33 -0500 Subject: [PATCH 3/8] docs(readme): Update badges for codecov & appveyor - Uses org appveyor account - Uses org standard codecov.io --- README.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index b6ff483a..8611b9f1 100644 --- a/README.md +++ b/README.md @@ -227,11 +227,11 @@ If you want to prepend Sass code before the actual entry file, you can set the ` [travis]: http://img.shields.io/travis/webpack-contrib/sass-loader.svg [travis-url]: https://travis-ci.org/webpack-contrib/sass-loader -[appveyor-url]: https://ci.appveyor.com/project/jhnns/sass-loader/branch/master -[appveyor]: https://ci.appveyor.com/api/projects/status/github/webpack-contrib/sass-loader?svg=true +[appveyor-url]: https://ci.appveyor.com/project/webpack-contrib/sass-loader/branch/master +[appveyor]: https://ci.appveyor.com/api/projects/status/rqpy1vaovh20ttxs/branch/master?svg=true -[cover]: https://coveralls.io/repos/github/webpack-contrib/sass-loader/badge.svg -[cover-url]: https://coveralls.io/github/webpack-contrib/sass-loader +[cover]: https://codecov.io/gh/webpack-contrib/sass-loader/branch/master/graph/badge.svg +[cover-url]: https://codecov.io/gh/webpack-contrib/sass-loader [chat]: https://badges.gitter.im/webpack/webpack.svg [chat-url]: https://gitter.im/webpack/webpack From ecb45f2ba758b6f76c7984097dec7235f2a880da Mon Sep 17 00:00:00 2001 From: Joshua Wiens Date: Wed, 14 Jun 2017 12:01:27 -0500 Subject: [PATCH 4/8] chore: Allow webpack 3 as peerDep & updates scripts - Adds npm scripts used by defualts builds - Sets engines to webpack standard - Allows webpack 3 rc & final as a peerDep --- package.json | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/package.json b/package.json index 5bc95472..4491d59b 100644 --- a/package.json +++ b/package.json @@ -4,17 +4,20 @@ "description": "Sass loader for webpack", "main": "lib/loader.js", "scripts": { + "appveyor:test": "npm test", "create-spec": "node test/tools/runCreateSpec.js", - "pretest": "npm run create-spec", + "lint": "eslint lib test", "test": "nyc --all mocha -R spec -t 10000", - "posttest": "npm run lint", "test-bootstrap-sass": "webpack-dev-server --config test/bootstrapSass/webpack.config.js --content-base ./test/bootstrapSass", "test-source-map": "webpack-dev-server --config test/sourceMap/webpack.config.js --content-base ./test/sourceMap --inline", "test-watch": "webpack --config test/watch/webpack.config.js", "test-extract-text": "webpack --config test/extractText/webpack.config.js", "test-hmr": "webpack-dev-server --config test/hmr/webpack.config.js --content-base ./test/hmr --hot --inline", - "lint": "eslint lib test", - "appveyor:test": "npm test" + "travis:lint": "npm run lint", + "travis:test": "npm run test", + "travis:coverage": "npm run test", + "pretest": "npm run create-spec", + "posttest": "npm run lint" }, "keywords": [ "sass", @@ -29,11 +32,11 @@ "author": "J. Tangelder", "license": "MIT", "engines": { - "node": ">=4.0.0" + "node": ">= 4.3 < 5.0.0 || >= 5.10" }, "peerDependencies": { "node-sass": "^4.0.0", - "webpack": "^2.0.0" + "webpack": "^2.0.0 || >= 3.0.0-rc.0 || ^3.0.0" }, "dependencies": { "async": "^2.1.5", From 0bb8db0f2d066f0402cb447b8f50b7806ba13150 Mon Sep 17 00:00:00 2001 From: Joshua Wiens Date: Wed, 14 Jun 2017 12:06:56 -0500 Subject: [PATCH 5/8] chore: Remove hard devDep on webpack - Both the Travis & Appveyor files install the node version they need --- package.json | 1 - 1 file changed, 1 deletion(-) diff --git a/package.json b/package.json index 4491d59b..7828b66c 100644 --- a/package.json +++ b/package.json @@ -58,7 +58,6 @@ "raw-loader": "^0.5.1", "should": "^11.2.0", "style-loader": "^0.18.2", - "webpack": "^2.2.1", "webpack-dev-server": "^2.4.1", "webpack-merge": "^4.0.0" }, From 5dae8c5089c3c9d12ee82a0f514072c6a0d5dee3 Mon Sep 17 00:00:00 2001 From: Joshua Wiens Date: Wed, 14 Jun 2017 12:09:59 -0500 Subject: [PATCH 6/8] chore(package): Tidy up package.json --- package.json | 46 ++++++++++++++++++++++------------------------ 1 file changed, 22 insertions(+), 24 deletions(-) diff --git a/package.json b/package.json index 7828b66c..3d9e6852 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,12 @@ "name": "sass-loader", "version": "6.0.5", "description": "Sass loader for webpack", + "author": "J. Tangelder", + "license": "MIT", "main": "lib/loader.js", + "files": [ + "lib" + ], "scripts": { "appveyor:test": "npm test", "create-spec": "node test/tools/runCreateSpec.js", @@ -19,25 +24,6 @@ "pretest": "npm run create-spec", "posttest": "npm run lint" }, - "keywords": [ - "sass", - "libsass", - "webpack", - "loader" - ], - "repository": { - "type": "git", - "url": "git://github.com/webpack-contrib/sass-loader.git" - }, - "author": "J. Tangelder", - "license": "MIT", - "engines": { - "node": ">= 4.3 < 5.0.0 || >= 5.10" - }, - "peerDependencies": { - "node-sass": "^4.0.0", - "webpack": "^2.0.0 || >= 3.0.0-rc.0 || ^3.0.0" - }, "dependencies": { "async": "^2.1.5", "clone-deep": "^0.3.0", @@ -61,9 +47,21 @@ "webpack-dev-server": "^2.4.1", "webpack-merge": "^4.0.0" }, - "files": [ - "lib", - "README", - "LICENSE" - ] + "engines": { + "node": ">= 4.3 < 5.0.0 || >= 5.10" + }, + "peerDependencies": { + "node-sass": "^4.0.0", + "webpack": "^2.0.0 || >= 3.0.0-rc.0 || ^3.0.0" + }, + "keywords": [ + "sass", + "libsass", + "webpack", + "loader" + ], + "repository": { + "type": "git", + "url": "git://github.com/webpack-contrib/sass-loader.git" + } } From f409dea05b5b9e0a408d92067574ec101073e995 Mon Sep 17 00:00:00 2001 From: Joshua Wiens Date: Wed, 14 Jun 2017 12:36:10 -0500 Subject: [PATCH 7/8] chore: Update repo meta --- package.json | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/package.json b/package.json index 3d9e6852..7afd3cba 100644 --- a/package.json +++ b/package.json @@ -60,8 +60,8 @@ "webpack", "loader" ], - "repository": { - "type": "git", - "url": "git://github.com/webpack-contrib/sass-loader.git" - } + "bugs": { + "url": "https://github.com/webpack-contrib/sass-loader/issues" + }, + "homepage": "https://github.com/webpack-contrib/sass-loader" } From a3dea517f3f9fe9bd2cc7a446be294d6370a0a65 Mon Sep 17 00:00:00 2001 From: Joshua Wiens Date: Wed, 14 Jun 2017 12:39:20 -0500 Subject: [PATCH 8/8] chore(pacakge): Add repo field back --- package.json | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/package.json b/package.json index 7afd3cba..a9056ea1 100644 --- a/package.json +++ b/package.json @@ -60,6 +60,10 @@ "webpack", "loader" ], + "repository": { + "type": "git", + "url": "git://github.com/webpack-contrib/sass-loader.git" + }, "bugs": { "url": "https://github.com/webpack-contrib/sass-loader/issues" },