feat: bundle OAuth client ID for jihulab.com authentication

Description

Add https://jihulab.com as a default option in the Authenticate command's instance URL picker, right after https://gitlab.com. A bundled OAuth client ID for jihulab.com is also registered so that JiHu GitLab users can sign in via OAuth out of the box, without having to type the instance URL or configure their own OAuth client.

Main changes:

  • src/common/constants.ts: Add a new JIHULAB_URL constant.
  • src/desktop/accounts/authenticate_command.ts: Include JIHULAB_URL alongside GITLAB_COM_URL as a default-prepended entry in the Authenticate command's instance URL list.
  • src/desktop/utils/extension_configuration.ts: Register a bundled OAuth client ID for JIHULAB_URL so it behaves the same as gitlab.com — OAuth login works without any extra setup.

Resolves #2292 (closed)

How has this been tested?

Manual testing locally:

  1. Run the GitLab: Authenticate command in VS Code.
  2. Verify that the URL picker shows https://gitlab.com as the first entry and https://jihulab.com as the second.
  3. Pick https://jihulab.com and confirm the OAuth flow starts with the bundled client ID — no extra configuration required.
  4. Pick https://gitlab.com and confirm the existing behavior is unchanged.
  5. Repeat the steps inside a repo that already has other GitLab remotes (e.g. a self-hosted instance), and confirm those instance URLs still appear in the list and that the dedup logic does not drop gitlab.com / jihulab.com.
  • If src/browser or src/common has been modified, please consider interoperability with the Web IDE. See Running the Extension in WebIDE.
  • Consider an end-to-end test for significant new features that aren't covered by integration tests.

Screenshots (if appropriate)

image image image

What CHANGELOG entry will this MR create?

  • fix: Bug fix fixes - a user-facing issue in production - included in changelog
  • feature: New feature - a user-facing change which adds functionality - included in changelog
  • BREAKING CHANGE: (fix or feature that would cause existing functionality to change) - should bump major version, mentioned in the changelog
  • None - other non-user-facing changes

/label ~"devops::ai-powered" groupeditor extensions ~"Category:Editor Extensions" ~"Editor Extensions::VS Code" sectiondev /assign me

Merge request reports

Loading
Loading