-
Notifications
You must be signed in to change notification settings - Fork 214
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
Support new type gh for template source #4203
Conversation
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.
Great work here, @vhvb1989. I'm guessing all the work we did to support different types of URLs is to make it easy for folks to copy and paste stuff into the terminal from wherever they find a github like URL.
I'm not sure if being stricter here and then allowing us to use a scheme based approach with the url
type is better. It would force more uniform URLs which might be harder for folks to construct, but on the other hand it feels like the use of these custom sources is really in some "I have some README.md in my team's onboarding wiki that tells me this command to run to get access to private AZD templates for my team" and the /author/ of that README.md
would have no problem coming up with the URL and writing it there.
I think the approach you took is a natural extension of the way the code works today, but I'm wondering if we should just lean into the URL idea (and that can be a way to support azdo
or something in the future maybe?
…e-dev into add-template-sourcetype-gh
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.
This is looking great but added some feedback I'd like to see addressed before we move forward with this PR.
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.
Overall LGTM, just left some minor comments
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.
Thank you @weikanglim
I have updated the code based on your feedback
Azure Dev CLI Install InstructionsInstall scriptsMacOS/Linux
bash:
pwsh:
WindowsPowerShell install
MSI install
Standalone Binary
MSI
Documentationlearn.microsoft.com documentationtitle: Azure Developer CLI reference
|
fix: #2996
the source
gh
allows folks to add a template source from a GitHub repository.azd uses gh-cli to authenticate to the GitHub hostname and then to use its authentication to fetch the content using the
api.github/repos
.Updating
template source add --help
to:Error messages for invalid urls:
https://raw.<hostName>...
https://api.<hostname>...
https://<hostname>....