Skip to content

Correct casing of GitHub in types for .NET and Go#453

Open
aaronpowell wants to merge 1 commit intogithub:mainfrom
aaronpowell:case-fixing
Open

Correct casing of GitHub in types for .NET and Go#453
aaronpowell wants to merge 1 commit intogithub:mainfrom
aaronpowell:case-fixing

Conversation

@aaronpowell
Copy link
Contributor

GitHub should have a capital H not lowercase, so correcting that in the type definitions for .NET and Go.

Not updating Python and TypeScript as they default to a lowercase first letter for properties, and that would result in gitHub which is equally incorrect.

@aaronpowell aaronpowell requested a review from a team as a code owner February 12, 2026 04:51
Copilot AI review requested due to automatic review settings February 12, 2026 04:51
Copy link
Contributor

Copilot AI left a 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 updates the Go and .NET SDK public option names to use the correct “GitHub” casing (and aligns docs/tests accordingly), plus includes a number of documentation formatting tweaks.

Changes:

  • Rename auth option from GithubTokenGitHubToken in Go and .NET types and update call sites/tests.
  • Update docs examples to use the corrected casing for Go/.NET.
  • Reformat multiple markdown files (spacing, tables, code blocks).

Reviewed changes

Copilot reviewed 14 out of 14 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
go/types.go Renames exported ClientOptions field to GitHubToken.
go/client.go Updates auth validation/CLI env wiring to use GitHubToken.
go/client_test.go Updates tests and expected panic message text for new casing.
go/internal/e2e/testharness/context.go Updates E2E harness to set GitHubToken in CI.
go/README.md Updates option documentation and adds formatting notes.
dotnet/src/Types.cs Renames public CopilotClientOptions property to GitHubToken.
dotnet/src/Client.cs Updates validation/CLI env wiring to use GitHubToken.
dotnet/test/ClientTests.cs Updates tests for new casing.
dotnet/test/Harness/E2ETestContext.cs Updates E2E harness to set GitHubToken in CI.
dotnet/README.md Updates option documentation and formatting.
docs/guides/setup/github-oauth.md Updates Go/.NET code samples to GitHubToken and reformats examples/tables.
docs/debugging.md Updates Go/.NET snippets to GitHubToken and formatting.
docs/auth/index.md Reformats authentication docs (tables/spacing) and updates samples.
.github/agents/docs-maintenance.agent.md Updates documentation-maintenance agent instructions and code-fence formatting.
Comments suppressed due to low confidence (3)

.github/agents/docs-maintenance.agent.md:267

  • This code block is opened with a triple-backtick fence earlier (), but it’s closed here with four backticks (````), which breaks markdown parsing. The closing fence should use the same number of backticks as the opener (likely here since no nesting is needed).
**.github/agents/docs-maintenance.agent.md:285**
* This `bash` code block is opened with ```bash but closed with ````. The fence length must match; use ``` to close (or change the opening fence to ````bash if nesting is required, which doesn’t appear to be the case here).
```
**.github/agents/docs-maintenance.agent.md:92**
* The outer fenced markdown block (opened with ````markdown) is being closed at line 92, but the example continues afterward; this leaves the rest of the example outside the fence and also makes the later closing fence inconsistent. The plan example should remain inside the outer fence until the end of the example and be closed with the same number of backticks.
```

// Should be:
await client.createSession();
```
</details>

Comment on lines 115 to 116
```

Copy link

Copilot AI Feb 12, 2026

Choose a reason for hiding this comment

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

This closing code fence (``` at line 115) no longer matches any opening fence after the earlier change to use ````markdown; it will break markdown rendering. Remove this stray fence or change it to the correct matching closing fence if the outer example block is intended to end here.

This issue also appears in the following locations of the same file:

  • line 267
  • line 285
  • line 88
Suggested change
```

Copilot uses AI. Check for mistakes.
// When provided, the token is passed to the CLI server via environment variable.
// This takes priority over other authentication methods.
GithubToken string
GitHubToken string
Copy link

Copilot AI Feb 12, 2026

Choose a reason for hiding this comment

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

Renaming the exported ClientOptions field from GithubToken to GitHubToken is a breaking API change for existing Go consumers (their code will no longer compile). Consider keeping a deprecated GithubToken alias field (with a // Deprecated: use GitHubToken. comment) and mapping it to GitHubToken inside NewClient (with a clear precedence rule if both are set).

Suggested change
GitHubToken string
GitHubToken string
// Deprecated: use GitHubToken.
GithubToken string

Copilot uses AI. Check for mistakes.
Comment on lines 44 to +47
/// When provided, the token is passed to the CLI server via environment variable.
/// This takes priority over other authentication methods.
/// </summary>
public string? GithubToken { get; set; }
public string? GitHubToken { get; set; }
Copy link

Copilot AI Feb 12, 2026

Choose a reason for hiding this comment

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

Changing CopilotClientOptions.GithubToken to GitHubToken is a breaking public API change for .NET callers. Consider keeping a [Obsolete] GithubToken property as a wrapper around GitHubToken (get/set forwarding) to preserve source compatibility while guiding users to the corrected casing.

Copilot uses AI. Check for mistakes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant