Where does Github desktop install command line version of Git

后端 未结 6 1347
无人及你
无人及你 2020-12-18 17:43

According to https://git-scm.com/book/en/v2/Getting-Started-Installing-Git

The installer includes a command line version of Git as well as the GUI. It

相关标签:
6条回答
  • 2020-12-18 18:17

    GithubDesktop install a Git shell with their desktop application. It seem to be locate in a same directory than their RIA application.

    If you have a shortcut created by installer GitHubDesktop you can retrieve the git shell location.

    0 讨论(0)
  • 2020-12-18 18:26

    0 讨论(0)
  • 2020-12-18 18:32

    git wants to simplify things so if you don't confortable with command line interface then you try git desktop if you want both command line and desktop GUI then install separate git from This URl https://git-scm.com/

    0 讨论(0)
  • 2020-12-18 18:34

    Goto Preferences an choose your Git-Shell. Thats it. Under default Shell you can choose between: CMD, Git Bash, Powershell or Custom.

    0 讨论(0)
  • 2020-12-18 18:37

    On Windows the latest Electron / unified versions of github desktop has git stored here:

    C:\Users\UserName\AppData\Local\GitHubDesktop\app-1.0.5\resources\app\git\cmd\git.exe
    
    0 讨论(0)
  • 2020-12-18 18:38

    If you are looking for the command line version of GIT with powershell and not CMD prompt like I was then this might help you.

    Github Desktop was changed from Chocolate-Covered Yaks (newest version 3.3.4.0) to a new native desktop which was redesigned with Electron. (It uses git version 2.11.0.windows.3)

    Unfortunately the new Github Desktop does not (yet) include a right click option to start PowerShell, like the old version did.

    So if you are stuck with the old Github Desktop Chocolate-Covered Yaks because you like the powershell option and you want to upgrade to a newer version of GIT, then you should look for a folder like this:

    Example: C:\Users{Your UserName}\AppData\Local\GitHub\PortableGit_{hex code which changes}\cmd (Example is for windows 7. For windows 10 I believe it is using \bin as folder name instead of \cmd

    The folder contains git.exe.

    Note this is a DIFFERENT folder placement than the new version of Github Desktop uses, which is why im adding this as an extra answer.

    I thought I could just replace git.exe with the newest version of git, but when I do that I get

    Git version
    "error launching git: The system cannot find the path specified."

    What in the end worked for me was to simply delete the git.exe from the PortableGit_{hex code which changes}\cmd folder.

    Since I had installed the Git separately in the newest version, it seems to default back to that and I get

    Git version
    git version 2.17.0.windows.1

    Note that if you delete the git.exe, Github Desktop v3.3.4.0 will stop working and the only thing you can use it for is to open the shell. For me thats perfect as I use the new Github Desktop anyways for anything but opening the shell.

    I also wanted to change editor. It is NOT enough to just install the new version of git and select notepad as editor. Somehow the powershell opened by the old Github Desktop still had its core.editor set to vim.

    I fixed it by typing the following in the power shell:

    git config core.editor "'C:\Program Files (x86)\Notepad++\notepad++.exe' -multiInst -notabbar -nosession -noPlugin"

    0 讨论(0)
提交回复
热议问题