switch to audit-filter npm pkg for nsp audit-filter

This commit is contained in:
Greg Guthe 2018-10-22 08:09:53 -04:00 коммит произвёл Andre Natal
Родитель d28ff77d6a
Коммит 398378fb87
3 изменённых файлов: 17 добавлений и 17 удалений

Просмотреть файл

@ -1,16 +0,0 @@
#!/bin/sh
set -ev
if [ -z ${CI+0} ]; then
echo "Skipping dep lint. (set CI != 0 to run locally)";
exit 0
fi
npm=$(npm prefix -g)/bin/npm
test -f bin/audit-filter || wget https://github.com/mozilla-services/audit-filter/releases/download/0.1.1/audit-filter-x86_64-unknown-linux-musl -O bin/audit-filter
echo "4aab86ced939727bc0d50ee5a14e01078b84217129017ed2b25c987acfe3771e bin/audit-filter" | sha256sum -c -
chmod +x bin/audit-filter
$npm --version
$npm audit --json | bin/audit-filter --nsp-config .nsprc

15
package-lock.json сгенерированный
Просмотреть файл

@ -120,6 +120,15 @@
"resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz",
"integrity": "sha1-x57Zf380y48robyXkLzDZkdLS3k=" "integrity": "sha1-x57Zf380y48robyXkLzDZkdLS3k="
}, },
"audit-filter": {
"version": "0.3.0",
"resolved": "https://registry.npmjs.org/audit-filter/-/audit-filter-0.3.0.tgz",
"integrity": "sha512-/JVgvA6bVj9D4Nw3ik6smcDTJFudUXGJApOlST3Lar17E1UjYYSSl9bc/ASZNg+2nJobqdQTZXsk21WrADtaew==",
"dev": true,
"requires": {
"docopt": "^0.6.2"
}
},
"aws-sdk": { "aws-sdk": {
"version": "2.287.0", "version": "2.287.0",
"resolved": "https://registry.npmjs.org/aws-sdk/-/aws-sdk-2.287.0.tgz", "resolved": "https://registry.npmjs.org/aws-sdk/-/aws-sdk-2.287.0.tgz",
@ -473,6 +482,12 @@
"resolved": "https://registry.npmjs.org/destroy/-/destroy-1.0.4.tgz", "resolved": "https://registry.npmjs.org/destroy/-/destroy-1.0.4.tgz",
"integrity": "sha1-l4hXRCxEdJ5CBmE+N5RiBYJqvYA=" "integrity": "sha1-l4hXRCxEdJ5CBmE+N5RiBYJqvYA="
}, },
"docopt": {
"version": "0.6.2",
"resolved": "https://registry.npmjs.org/docopt/-/docopt-0.6.2.tgz",
"integrity": "sha1-so6eIiDaXsSffqW7JKR3h0Be6xE=",
"dev": true
},
"doctrine": { "doctrine": {
"version": "2.1.0", "version": "2.1.0",
"resolved": "https://registry.npmjs.org/doctrine/-/doctrine-2.1.0.tgz", "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-2.1.0.tgz",

Просмотреть файл

@ -13,6 +13,7 @@
"uuid": "^3.3.2" "uuid": "^3.3.2"
}, },
"devDependencies": { "devDependencies": {
"audit-filter": "^0.3.0",
"eslint": "^4.19.1", "eslint": "^4.19.1",
"prettier": "^1.14.0" "prettier": "^1.14.0"
}, },
@ -22,7 +23,7 @@
"scripts": { "scripts": {
"format": "prettier server.js --single-quote --write", "format": "prettier server.js --single-quote --write",
"lint": "eslint .", "lint": "eslint .",
"lint:deps": "./bin/filtered_npm_audit.sh", "lint:deps": "npm audit --json | audit-filter --nsp-config=.nsprc --audit=-",
"start": "node server", "start": "node server",
"test": "npm run lint" "test": "npm run lint"
} }