Move to using the catch-uncommitted npm package

This commit is contained in:
Tim Perry 2017-09-14 15:59:31 +02:00
parent 950201973b
commit 62035fac83
3 changed files with 5 additions and 18 deletions

View File

@ -7,7 +7,7 @@ matrix:
- CAN_DEPLOY=true
before_install:
- npm -g install npm@4
script: ./automation/catch-uncommitted-output.sh
script: npm run ci
notifications:
email: false
deploy:

View File

@ -1,15 +0,0 @@
#!/bin/sh
set -e
npm run build
echo
if ! git diff HEAD --exit-code ; then
echo '** Uncommitted changes found after build - FAIL **'
exit 1
elif test -n "$(git ls-files --exclude-standard --others | tee /dev/tty)" ; then
echo '** Untracked uncommitted files found after build (^^^ listed above ^^^) - FAIL **'
exit 2
else
echo 'No unexpected changes after build, all good.'
fi

View File

@ -14,11 +14,12 @@
},
"scripts": {
"build": "gulp build && npm run doc",
"ci": "npm run build && catch-uncommitted",
"doc": "mkdir -p doc/ && coffee extras/capitanodoc/index.coffee > doc/cli.markdown",
"watch": "gulp watch",
"lint": "gulp lint",
"prepublish": "require-npm4-to-publish",
"prepublishOnly": "npm run build && npm run doc"
"prepublishOnly": "npm run build"
},
"keywords": [
"resin",
@ -30,6 +31,7 @@
"node": ">=6.0"
},
"devDependencies": {
"catch-uncommitted": "^1.0.0",
"ent": "^2.2.0",
"gulp": "^3.9.0",
"gulp-coffee": "^2.2.0",
@ -101,4 +103,4 @@
"optionalDependencies": {
"removedrive": "^1.0.0"
}
}
}