-
Notifications
You must be signed in to change notification settings - Fork 149
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
fix: make API urls from GitGuardian work with GGShield #1045
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #1045 +/- ##
=======================================
Coverage 91.75% 91.75%
=======================================
Files 143 143
Lines 6040 6043 +3
=======================================
+ Hits 5542 5545 +3
Misses 498 498
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
759457d
to
df36e15
Compare
198144f
to
a0734ee
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me ! Thanks for the improvement, I just have a small comment.
to answer you both @gg-jonathangriffe and @agateau-gg: I think on-prem urls should be handled as well, as the issue encountered by one of GitGuardian customer with the VSCode Extension could happen too. The API url looks like this for an on-prem customer. I'm going to adapt this MR and add a test for this use case. |
See last commit |
c8761c1
to
c0f69ec
Compare
@gg-jonathangriffe & @agateau-gg : I finished manual checks, this PR is ready for re-review |
ce964f3
to
c5e624b
Compare
c5e624b
to
cc27bb4
Compare
Context
See GitGuardian/gitguardian-vscode#67
What has been done
When running
ggshield cmd --instance ${INSTANCE}
, ifINSTANCE
matches any of the URLs mentioned https://api.eu1.gitguardian.com/docs, it is replaced by the relevant URL.Validation
Validate with GGShield
ggshield
command having the--instance
option available with--instance https://api.gitguardian.com/v1
or--instance https://api.eu1.gitguardian.com/v1
--instance https://dashboard.gitguardian.com/
or--instance https://dashboard.eu1.gitguardian.com/
Validate with VSCode Extension
main
at https://github.com/GitGuardian/gitguardian-vscodePR check list
skip-changelog
label has been added to the PR.