Fix PackAsTool runtime asset publishing - #2557
Open
kondv wants to merge 1 commit into
Open
Conversation
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
The Windows net472 test build cannot resolve ZipFile without System.IO.Compression.FileSystem.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Pull request overview
Fixes PackAsTool publishing so RID-specific packages include usable Copilot CLI runtime assets.
Changes:
- Publishes runtime assets and compatibility markers.
- Restores Unix executable permissions.
- Adds cross-platform packaging, launch tests, and CI coverage.
File summaries
| File | Description |
|---|---|
dotnet/test/Unit/RuntimeWrapperTests.cs |
Tests CLI precedence and Unix executable restoration. |
dotnet/test/Unit/MSBuildTargetsTests.cs |
Tests RID-specific tool packaging. |
dotnet/test/GitHub.Copilot.SDK.Test.csproj |
Updates test-project compression references, but lacks the required System.IO.Compression.FileSystem reference for net472. |
dotnet/src/Client.cs |
Handles compatibility markers and Unix permissions. |
dotnet/src/build/GitHub.Copilot.SDK.targets |
Publishes RID-specific runtime assets. |
.github/workflows/dotnet-sdk-tests.yml |
Adds Unix .NET 6–8 compatibility coverage. |
Review details
- Files reviewed: 6/6 changed files
- Comments generated: 1
- Review effort level: Balanced
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
| <Compile Include="..\src\Polyfills\*.cs" Link="Polyfills\%(Filename)%(Extension)" /> | ||
| <PackageReference Include="Microsoft.Bcl.Memory" /> | ||
| <PackageReference Include="System.Net.Http.Json" /> | ||
| <Reference Include="System.IO.Compression" /> |
kondv
force-pushed
the
dev/kondv/packastool-runtime-assets
branch
from
September 7, 2026 11:31
fcb3eaa to
e68a27a
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #2067
Summary
Make
PackAsToolpublish Copilot CLI runtime assets into RID-specific tool packages instead of leaving them only in build output.The targets now preserve explicit CLI precedence, replace changed explicit binaries regardless of timestamps, package the compatibility marker, and include each requested runtime. The runtime restores Unix execute permissions through a
netstandard2.0-compatible native fallback. Tests and CI cover Windows, Linux, and macOS packages plus .NET 6/7/8 Unix launch behavior.Validation
PackAsToolprojectwin-x64,linux-x64, andosx-x64packages and their runtime/marker entries