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: AMA-3307-fix-scan-usage-showing-on-error-vjeran #305

Merged
merged 8 commits into from
Dec 20, 2022

Conversation

vjerci
Copy link
Contributor

@vjerci vjerci commented Dec 20, 2022

Description

  1. This pr makes sure flags containg custom predefined values are valid, before running the scan.
    In case you input value that is not in predefined values list as in this example(--report=test) usage will show with error:

Screenshot 2022-12-20 at 14 31 59

  1. If scan errors, command usage is no longer shown

Screenshot 2022-12-20 at 14 37 11

Checklist

  • I've added test coverage that shows my fix or feature works as expected.
  • PR title follows Conventional Commits format

@swarmia
Copy link

swarmia bot commented Dec 20, 2022

Copy link
Contributor

@spdawson spdawson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good; few small suggestions to improve wording of error messages 🙂

pkg/flag/report_flags.go Outdated Show resolved Hide resolved
pkg/flag/report_flags.go Outdated Show resolved Hide resolved
pkg/flag/scan_flags.go Outdated Show resolved Hide resolved
vjerci and others added 4 commits December 20, 2022 15:25
Co-authored-by: Simon Dawson <spdawson@gmail.com>
Co-authored-by: Simon Dawson <spdawson@gmail.com>
Co-authored-by: Simon Dawson <spdawson@gmail.com>
@vjerci vjerci merged commit 9944c12 into main Dec 20, 2022
@vjerci vjerci deleted the AMA-3307-fix-scan-usage-showing-on-error-vjeran branch December 20, 2022 14:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants