v1.0.0-beta.4Free and open source, MIT license

Wear the right identityeverywhere.

Switch between accounts on GitHub, GitLab, Bitbucket, Hugging Face or any other git host in one click, and manage every server in your SSH config from one list.

Other platforms · Windows, macOS and Linux

Lanyard
Lanyard overview: active git accounts per provider and the list of SSH serversLanyard overview: active git accounts per provider and the list of SSH servers

THE PROBLEM

Two GitHub accounts, one git@github.com

SSH offers whichever key it finds first. Pushes to a client repo fail, or go through under the wrong account with the wrong email on every commit.

Without Lanyard
$ git push
ERROR: Permission to acme/app.git denied to jane-personal.
fatal: Could not read from remote repository.
With Lanyard
$ lanyard use github work
$ git push
To github.com:acme/app.git
   3f2a1c9..8b4e0d2  main -> main

Lanyard points git@github.com at the account you pick, sets the commit name and email to match, and gives each account its own alias host for the times you need both.

Pick the account. Git follows.

Add each account once with its own SSH key, name and email. Switching rewrites only what git needs, on any host you push to over SSH.

  • GitHub
  • GitLab
  • Bitbucket
  • Hugging Face
  • Azure DevOps
  • Codeberg
  • Gitea
  • SourceHut
  • Self-hosted, or any git host over SSH
Git accounts screen: GitHub, GitLab and Hugging Face with the active account marked and its alias host

Switch in one click

Choose the active account per provider. Plain git@github.com URLs use its key, and commits carry its name and email.

Two accounts side by side

Every account also gets an alias host. Clone with git@github.com-work and that repo stays on work, whatever is active.

Test before you push

Check each account against its provider and see which identity answers, before a push goes out under the wrong one.

Every server in ~/.ssh/config, in one list.

Lanyard reads the Host entries you already have. Edits keep your comments and formatting, and every change is backed up first.

Hosts screen: servers with their target and the SSH key each one uses
Host editor dialog for prod-web: HostName, User, Port, IdentityFile and ProxyJump fields

Connect in one click

Open a terminal session on any server from the list, the palette or the tray.

Switch keys per server

Pick the IdentityFile for each host from the keys in ~/.ssh.

Jump hosts

Reach private machines through a bastion with ProxyJump or ProxyCommand.

Trust host keys safely

Scan a server, compare its fingerprints with the published ones, then trust it.

Keys, agent, known hosts and backups.

SSH keys

Generate keys, add or change passphrases, and see which account or server uses each one.

Keys list with fingerprints and the accounts and hosts that use each key

ssh-agent

See whether the agent is running and load keys into it, so a passphrase is asked for once.

Overview cards showing key count and ssh-agent status

Known hosts

Scan a host and check its fingerprints before trusting it. Remove stale entries after a server is rebuilt.

Scan host keys dialog listing RSA, ECDSA and ED25519 fingerprints for gitlab.com

Automatic backups

A snapshot of your config or known_hosts is taken before every change. Restore any of them in one click.

Backups list with timestamps next to the contents of the selected snapshot

A shortcut away, from anywhere.

System tray

Lanyard lives in the tray. Switch an account or connect to a server from its menu without opening the window.

Command paletteCtrlKor⌘K

Type to find an account, a host or an action, then press Enter.

Keyboard first

↑↓to move,↵to run,escto close.

Command palette with sections for switching accounts, connecting to hosts and running actions

Everything, from the terminal.

The app and the lanyard CLI share the same config, so scripts and the window always agree. lny is the short alias.

Install globally

$ npm install -g lanyard-cli

Or run without installing

$ npx lanyard-cli status
~/code
# who is active on each host
$ lanyard status
# switch GitHub to the personal account
$ lanyard use github personal
# clone through the work account
$ git clone $(lanyard url github work https://github.com/acme/app)
# change the key a server uses
$ lanyard hosts key prod id_ed25519_servers
# open an SSH session
$ lanyard connect prod

One marked block. The rest is untouched.

Lanyard writes its entries between two marker comments in ~/.ssh/config. Everything outside them stays exactly as you wrote it.

  • Backups before every change

    Your config and known_hosts are snapshotted before each write, and any snapshot can be restored.

  • Locked-down window

    The app's window has no access to your files and can only call Lanyard's own API. The source is on GitHub for anyone to review.

  • Passphrases never stored

    They go straight to OpenSSH and are never saved by Lanyard.

~/.ssh/config
# >>> lanyard managed section >>>
# Generated by Lanyard. Change these entries from the app or the
# `lanyard` CLI - manual edits inside this section are overwritten.
Host github.com
User git
IdentityFile ~/.ssh/id_ed25519_github_work
IdentitiesOnly yes
Host github.com-personal
HostName github.com
IdentityFile ~/.ssh/id_ed25519_github_personal
# <<< lanyard managed section <<<
# Your own entries
Host *
ServerAliveInterval 60
AddKeysToAgent yes
Host nas
HostName 192.168.1.40
User admin

Free for Windows, macOS and Linux.

v1.0.0-beta.4 · MIT license · Release notes

CLI only

Any platform with Node.js 20+

npm i -g lanyard-cli

Builds are not code-signed yet, so your OS will warn on first launch.

Windows: in the SmartScreen dialog, choose More info → Run anyway.

macOS: right-click Lanyard in Applications and choose Open.

Every file has a signed build attestation and a published checksum. See the code signing policy to verify a download.