Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: exit code 0 if nothing is vulnerable #1886

Merged
merged 1 commit into from May 5, 2021
Merged

Conversation

lili2311
Copy link
Contributor

@lili2311 lili2311 commented May 5, 2021

What does this PR do?

Improve exit code to help action snyk fix output when composing inside pipelines/scripts.

  • If snyk test failed => error ❌
  • If snyk test returned no vulnerable results => success ✅
  • If snyk fix had some errors and nothing was fixed => error ❌
  • If snyk fix fixed anyrying at all => success ✅

Improve exit code to help action `snyk fix` output.
If `snyk test` failed => error
If `snyk test` returned no vulnerable results => success
If `snyk fix` had some errors and nothing was fixed => error
If `snyk fix` fixed anyrying at all => success
@lili2311 lili2311 self-assigned this May 5, 2021
@github-actions
Copy link
Contributor

github-actions bot commented May 5, 2021

Expected release notes (by @lili2311)

features:
exit code 0 if nothing is vulnerable (a04a1a9)

  • I hereby acknowledge these release notes are 🥙 AWESOME 🥙

@github-actions
Copy link
Contributor

github-actions bot commented May 5, 2021

Warnings
⚠️

Looks like you added a new Tap test. Consider making it a Jest test instead. See files like test/*.spec.ts for examples. Files found:

  • test/fixtures/snyk-fix/test-result-pip-no-vulns.json

Generated by 🚫 dangerJS against a04a1a9

@lili2311 lili2311 marked this pull request as ready for review May 5, 2021 11:19
@lili2311 lili2311 requested review from a team as code owners May 5, 2021 11:19
@lili2311 lili2311 merged commit 7bc9229 into master May 5, 2021
@lili2311 lili2311 deleted the fix/error-code-0 branch May 5, 2021 12:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants