Skip to content

csharp.sh: add post-generation guidance for dotnet build step#298

Merged
k8s-ci-robot merged 2 commits intomasterfrom
copilot/fix-csharp-generator-script
Mar 30, 2026
Merged

csharp.sh: add post-generation guidance for dotnet build step#298
k8s-ci-robot merged 2 commits intomasterfrom
copilot/fix-csharp-generator-script

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Mar 26, 2026

Unlike other language generators, csharp.sh only produces swagger.json — actual C# code generation requires running dotnet build in the C# client repo. This left users confused when only swagger.json and swagger.json.unprocessed appeared in the output directory.

Changes

  • openapi/csharp.sh: Adds a post-run message explaining the two-step nature of C# generation, including the exact commands to copy the generated swagger.json into the C# client repo and trigger code generation via dotnet build:
NOTE: Unlike other generators, the C# client does not generate code directly.
The swagger.json has been placed in: <OUTPUT_DIR>

To generate the C# client code, clone the C# client repository and run dotnet build:
  git clone https://github.com/kubernetes-client/csharp
  cp <OUTPUT_DIR>/swagger.json csharp/src/KubernetesClient/swagger.json
  cd csharp
  dotnet build

For more details, see: https://github.com/kubernetes-client/csharp/tree/master/gen/LibKubernetesGenerator

💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

@k8s-ci-robot k8s-ci-robot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Mar 26, 2026
Copilot AI linked an issue Mar 26, 2026 that may be closed by this pull request
@k8s-ci-robot k8s-ci-robot added size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. labels Mar 26, 2026
@k8s-ci-robot k8s-ci-robot added size/S Denotes a PR that changes 10-29 lines, ignoring generated files. and removed size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Mar 26, 2026
Copilot AI changed the title [WIP] Fix generator script for C# code generation csharp.sh: add post-generation guidance for dotnet build step Mar 26, 2026
Copilot AI requested a review from brendandburns March 26, 2026 21:39
@brendandburns brendandburns marked this pull request as ready for review March 30, 2026 18:30
@k8s-ci-robot k8s-ci-robot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Mar 30, 2026
Copy link
Copy Markdown
Contributor

@brendandburns brendandburns left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm
/approve

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Mar 30, 2026
@k8s-ci-robot
Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: brendandburns, Copilot

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Mar 30, 2026
@k8s-ci-robot k8s-ci-robot merged commit 42d3af6 into master Mar 30, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

The generator script ./openapi/csharp.sh doesn't work

3 participants