Skip to content

Set up your Git identity and an SSH key on Windows

A fresh PC needs two things before you can push code: who you are, and a key for GitHub. Devpit sets both up in a few keystrokes.

Open it from the main menu with 6, or choose Git & SSH Setup. You need Git installed. If it is missing, Devpit says so. You can install it with Install developer apps.

Choose Show git identity. Devpit shows the name and email Git will use for your commits. If one is missing it says “(not set)”.

  1. Choose Set git identity.
  2. Type your name. Press Tab to move to the email field and type your email. Devpit fills in what is already set.
  3. Press Enter to review.
  4. Read the question. It says the change applies to every repository, through your .gitconfig. The default answer is No.
  5. Press y. Devpit saves both values and says “Git identity saved.”

This is the same as running:

Terminal window
git config --global user.name "Your Name"
git config --global user.email "you@example.com"

Use the email that your GitHub account uses, so commits are linked to you.

Devpit creates an ed25519 key, a modern and short key type. It needs ssh-keygen, which comes with the OpenSSH client that is part of Windows.

  1. Choose Generate SSH key.

  2. Devpit checks whether a key already exists at %USERPROFILE%\.ssh\id_ed25519.

    • No key: it creates one at once. The comment in the key is your Git email, if one is set.
    • A key exists: it stops and asks you to type OVERWRITE. Read the warning first: the old key stops working everywhere it was added. Answer No to keep it.
  3. When it is done you see the path and the public key.

  4. Press c to copy the public key to the clipboard.

  5. Press Enter to go back.

  1. Open github.com/settings/keys.

  2. Click New SSH key.

  3. Give it a title, for example the name of your PC.

  4. Paste the public key you copied and save.

  5. Test it in a terminal:

    Terminal window
    ssh -T git@github.com

    The first time, SSH asks if you trust the host. Check that it is GitHub, then type yes. GitHub answers with a “successfully authenticated” message and your user name.

Key What it does
↑ ↓ Move in the menu
Enter Choose, review or go back
Tab Switch between the name and email fields
y / n Answer a question (No is the default)
c Copy the public key
Esc Go back

See Keyboard and mouse for every key.

  • An existing SSH key is never replaced without you typing OVERWRITE.
  • Nothing is written to your Git settings until you answer Yes.
  • Devpit never uploads your key. It only shows it and copies it to your clipboard when you press c.

Common questions

Will Devpit overwrite my existing SSH key?

Not without a typed confirmation. If a key already exists, Devpit asks you to type OVERWRITE first, and warns that the old key stops working everywhere it was added. Answering No leaves everything as it was.

Does the SSH key have a passphrase?

No. Devpit creates the key without a passphrase, so it can be used without typing one. Anyone who can read the file can use the key. If you want a passphrase, run ssh-keygen -p -f on the key file afterwards.

Where is the key saved?

In the .ssh folder of your user profile: id_ed25519 for the private key and id_ed25519.pub for the public key. The private key never leaves that folder.

Does Set git identity change every repository?

Yes. It changes your global Git settings in your .gitconfig file, so it applies to every repository that has no setting of its own.

Devpit says git is not installed. What do I do?

Install Git first. You can do that from Install Developer Apps in Devpit, then come back to this screen.