-
Notifications
You must be signed in to change notification settings - Fork 227
Allow TypeSpec project path to be a github link #13517
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
base: main
Are you sure you want to change the base?
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.
Pull request overview
This PR adds support for using GitHub URLs as TypeSpec project paths in addition to local filesystem paths. The implementation allows users to reference TypeSpec projects directly via URLs like https://github.com/Azure/azure-rest-api-specs/blob/main/specification/service/Service.Management.
Key changes:
- Added URL validation for GitHub spec repository URLs with pattern matching
- Extended core TypeSpec helper methods to detect and handle URL inputs
- Enhanced management plane detection to infer from URL path patterns when config files aren't accessible
- Comprehensive test coverage for URL-based operations
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| tools/azsdk-cli/Azure.Sdk.Tools.Cli/Helpers/TypeSpecHelper.cs | Added URL detection and validation logic, extended existing methods to handle both local paths and GitHub URLs |
| tools/azsdk-cli/Azure.Sdk.Tools.Cli.Tests/Helpers/TypeSpecHelperTests.cs | Added comprehensive test cases for URL validation, management plane detection, and path operations with URLs |
| tools/azsdk-cli/Azure.Sdk.Tools.Cli.Tests/Tools/ReleasePlan/ReleasePlanToolTests.cs | Replaced mock TypeSpecHelper with real implementation and added integration test using GitHub URL |
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.
Pull request overview
Copilot reviewed 4 out of 4 changed files in this pull request and generated 5 comments.
Resolves: #13488