https://github.com/umutphp/gitlabci-npm-audit-script
The script for adding "npm audit" as a step to GitlabCI pipeline.
https://github.com/umutphp/gitlabci-npm-audit-script
audit-script gitlab-ci gitlabci-pipeline npm npm-audit shell shell-script
Last synced: 27 days ago
JSON representation
The script for adding "npm audit" as a step to GitlabCI pipeline.
- Host: GitHub
- URL: https://github.com/umutphp/gitlabci-npm-audit-script
- Owner: umutphp
- Created: 2018-12-18T21:17:44.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2019-06-18T06:30:17.000Z (almost 6 years ago)
- Last Synced: 2023-03-05T21:41:14.364Z (about 2 years ago)
- Topics: audit-script, gitlab-ci, gitlabci-pipeline, npm, npm-audit, shell, shell-script
- Language: Shell
- Homepage:
- Size: 2.93 KB
- Stars: 1
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# gitlabci-npm-audit-script
The script is for adding 'npm audit' as a step to GitlabCI pipeline. [stedolan/jq/](https://github.com/stedolan/jq/) is used to parse the json on bash.The script parses the 'npm audit' result json and gives the proper exit code. When 'Exit 1' is fired, a summary and a detailed json is displayed.
A sample step definition in .gitlab-ci.yml would be;
```
test_async:
stage: check
image:node
script:
- bash /path/to/npm-audit-step.sh
```