How to Check for Git Installation

It’s easy to check if Git is already installed on your computer.

  1. Open the Terminal in RStudio:

    • In RStudio, go to the Terminal tab (bottom left window) or Tools > Terminal > New Terminal. This will open a command-line interface directly within RStudio. You can also open the existing terminal window, bottom left, right of the ‘Console’ tab.
  2. Type the command and press Enter:

    git --version

    ! If you want to copy and paste, but it doesn’t work with Ctrl + V or Cmd + V, use Shift + Insert, or Edit->Paste

  3. Interpret the output:

    • If Git IS installed: You will see a message like this, indicating the version number:

      git version 2.45.2.windows.1 # (Version number will vary)

      If you see this, great! You have Git. You can continue with the next steps:
      Go back and proceed on the GitHub Desktop page

    • If Git is NOT installed: You will see an error message, which varies slightly by operating system:

      • On Windows:

        'git' is not recognized as an internal or external command,
        operable program or batch file.

        or ``` The term ‘git’ is not recognized as the name of a cmdlet, function, script file, or operable program.

        ```

      • On macOS / Linux: bash: git: command not found or zsh: command not found: git If you see any of these error messages, Git is not installed or not correctly configured in your system’s PATH. Please proceed to the installation steps below for your operating system.

(Need to Install Standalone Git? (only do this after you installed GitHub Desktop and you can’t use the Git version from that installation for some reason)

(Just in case we need to authenticate for GitHUb access with a Personal Access Token (PAT), instructions are here)

Proceed with GitHub Desktop workflow | Return to Section Overview