-
Notifications
You must be signed in to change notification settings - Fork 360
[EngSys] Replace GenAPI tool with GenAPI MSBuild task in Export-Api.ps1 #909
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
Conversation
|
@copilot Modify the Export-Api.ps1 script in this PR so that it deletes the contents of the "api" folder before running the GenAPI task. |
|
@joseharriaga I've opened a new pull request, #910, to work on those changes. Once the pull request is ready, I'll request review from you. |
* Initial plan * Delete api folder contents before running GenAPI Co-authored-by: joseharriaga <[email protected]> * Add error handling and recursive cleanup for api folder Co-authored-by: joseharriaga <[email protected]> * Optimize api folder cleanup command Co-authored-by: joseharriaga <[email protected]> * Use Join-Path for cross-platform compatibility Co-authored-by: joseharriaga <[email protected]> * Ensure cleanup includes hidden files Co-authored-by: joseharriaga <[email protected]> --------- Co-authored-by: copilot-swe-agent[bot] <[email protected]> Co-authored-by: joseharriaga <[email protected]>
|
@copilot Simplify the changes in this PR by taking the following into consideration:
|
|
@joseharriaga I've opened a new pull request, #911, to work on those changes. Once the pull request is ready, I'll request review from you. |
… parameters (#911) - **Removed `Configuration` parameter** - Now hardcoded to "Release" - **Removed `TargetFramework` parameter** - Always processes all TFMs from `ClientTargetFrameworks` in Directory.Build.props - **Updated script documentation** - Removed parameter documentation and examples to reflect single-purpose behavior - **Fixed MSBuild invocation** - Modified script to explicitly iterate over each target framework (net10.0, net8.0, netstandard2.0) to ensure the ExportApi MSBuild target runs correctly for multi-targeted projects
|
@copilot The current Export-Api.ps1 script in this PR runs |
|
@joseharriaga I've opened a new pull request, #918, to work on those changes. Once the pull request is ready, I'll request review from you. |
- **MSBuild Integration**: Added `ExportApi` target in `Directory.Build.targets` that uses an outer/inner build pattern to automatically handle all target frameworks - **Outer build target**: Dispatches to inner builds for each target framework when building a multi-targeted project - **Inner build target** (`ExportApiInner`): Invokes GenAPITask for each specific target framework - **Export Script**: Created `Export-Api.ps1` PowerShell script that: - Cleans the `api/` folder before generation - Runs a single build command with the `ExportApi` target (MSBuild automatically handles all TFMs: net10.0, net8.0, netstandard2.0) - Post-processes generated files to remove fully-qualified names, internal APIs, and unwanted attributes - Always uses Release configuration
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.
Nice!
Uh oh!
There was an error while loading. Please reload this page.