Skip to content

Pin Cursor password store to gnome-libsecret so GitHub login can use the OS keyring - #8441

Open
MrBazzieB wants to merge 1 commit into
omacom:quattrofrom
MrBazzieB:fix/cursor-os-keyring
Open

MrBazzieB wants to merge 1 commit into
omacom:quattrofrom
MrBazzieB:fix/cursor-os-keyring

Conversation

@MrBazzieB

Copy link
Copy Markdown
Contributor

Problem

Signing into GitHub from Cursor on Omarchy shows:

An OS keyring couldn't be identified for storing the encryption related data in your current desktop environment.

Omarchy already runs GNOME Keyring (org.freedesktop.secrets). The failure is on the Cursor side: it is an Electron/VS Code fork, and Chromium os_crypt cannot auto-detect GNOME Keyring when XDG_CURRENT_DESKTOP=Hyprland.

VS Code already avoids this by writing "password-store": "gnome-libsecret" to ~/.vscode/argv.json in omarchy-install-editor-vscode. Cursor was installed through the generic omarchy-install-and-launch path and never got that pin.

Related: #1015 (VS Code), and the Chromium --password-store=gnome-libsecret pin in config/chromium-flags.conf.

Change

  • Add omarchy-install-editor-cursor, matching the VS Code installer: package, pin ~/.cursor/argv.json, apply the Omarchy theme, launch.
  • Route Install → Editor → Cursor and omarchy default editor cursor through that installer.
  • Migrate existing Cursor installs: write or insert gnome-libsecret when password-store is missing, leave an explicit value (including basic) alone.

New installs pick this up from the installer. Existing installs pick it up on the next omarchy update. Cursor still has to be restarted once after the pin.

Test plan

  • bash test/shell.d/cursor-password-store-migration-test.sh
  • bash test/shell.d/desktop-entry-launch-test.sh
  • bash test/shell.d/default-apps-test.sh
  • ./test/all — remaining failures are pre-existing on quattro in this environment (missing omarchy-pkgs checkout, About animation, theme-install URL check)

…the OS keyring

Cursor is a VS Code fork, so Electron encrypts GitHub tokens with Chromium
os_crypt. On Hyprland, XDG_CURRENT_DESKTOP is not a desktop Electron
recognizes, so it cannot identify GNOME Keyring and GitHub login offers
"weaker encryption" instead.

VS Code already writes password-store=gnome-libsecret into argv.json at
install time. Cursor went through the generic package launcher and never
got that pin. Give it the same dedicated installer, and migrate existing
~/.cursor/argv.json files without clobbering an explicit password-store.
Copilot AI balanced review requested due to automatic review settings August 26, 2026 18:27

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Adds Cursor-specific installation and migration support to enable GNOME Keyring-backed GitHub authentication.

Changes:

  • Adds a Cursor installer with keyring and theme configuration.
  • Routes menu and default-editor installs through it.
  • Migrates existing Cursor configurations and adds tests.

Tip

If you aren't ready for review, convert to a draft PR.
Click "Convert to draft" or run gh pr ready --undo.
Click "Ready for review" or run gh pr ready to reengage.

Reviewed changes

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

Show a summary per file
File Description
bin/omarchy-install-editor-cursor Adds the Cursor installer.
bin/omarchy-default-editor Routes Cursor installation.
default/omarchy/omarchy-menu.jsonc Updates the Cursor menu action.
migrations/1787689809.sh Migrates existing Cursor settings.
test/shell.d/cursor-password-store-migration-test.sh Tests migration behavior.
test/shell.d/default-apps-test.sh Tests default-editor routing.
test/shell.d/desktop-entry-launch-test.sh Tests installer configuration and launch.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread migrations/1787689809.sh
# argv.json pin VS Code writes at install time. Leave an explicit password-store
# alone so a user who chose "basic" is not silently moved.

if [[ -d $HOME/.cursor ]] || omarchy-cmd-present cursor; then
Comment thread migrations/1787689809.sh
"password-store": "gnome-libsecret"
}
EOF
elif ! grep -q '"password-store"' "$argv"; then
Comment thread migrations/1787689809.sh
Comment on lines +30 to +34
head = text[:idx].rstrip()
if head.endswith("{") or head.endswith(","):
insert = '\n "password-store": "gnome-libsecret"\n'
else:
insert = ',\n "password-store": "gnome-libsecret"\n'
@baseman70

Copy link
Copy Markdown

Great addition! The gnome-libsecret pin in argv.json is definitely needed for GitHub auth in Cursor on Hyprland.

One related issue worth catching here: on Arch Linux, Cursor's built-in updater defaults to a Debian/Ubuntu auto-update flow. On a fresh install, Cursor immediately detects newer upstream releases and silently downloads a .deb package (e.g. cursor_3.19.13_amd64.deb) into ~/Downloads/, popping up an "Update downloaded" notification that Arch users cannot install directly.

In bin/omarchy-install-editor-vscode, Omarchy prevents this by setting "update.mode": "none" in settings.json:

# Ensure VSC's own auto-update feature is turned off
printf '{\n  "update.mode": "none"\n}\n' > ~/.config/Code/User/settings.json

We should add the equivalent to bin/omarchy-install-editor-cursor so Cursor delegates package updates to pacman / yay:

# Ensure Cursor's own auto-update feature is turned off (managed via pacman/AUR)
if [[ ! -f ~/.config/Cursor/User/settings.json ]]; then
  printf '{\n  "update.mode": "none"\n}\n' > ~/.config/Cursor/User/settings.json
fi

(And optionally in the migration script if settings.json already exists). This would prevent new users from getting confused by unusable .deb downloads in their Downloads directory.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants