Kann sich zu Github verpflichten [Duplikat]

Aug 18 2020

Ich habe ein Projekt vorbereitet und möchte mich für Github engagieren. A haben auch Git + GitHub Desktop und verwenden VSCode und Terminal darin. Wenn ich also versuche, 'git' vom Terminal in VSCode im Ordner mit dem Projekt zu überprüfen, habe ich das Problem:

git : The term 'git' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1
+ git
+ ~~~
    + CategoryInfo          : ObjectNotFound: (git:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

Bei Verwendung von Common Cmd ist alles in Ordnung! Wie könnte ich das beheben?

Antworten

albeksdurf Aug 18 2020 at 10:18

Dies liegt daran, dass Ihr gitausführbares git.exeVerzeichnis ( ) nicht in der PATHVariablen eingerichtet ist und PowerShell es daher nicht finden kann.

Sie müssen den Ordner suchen, in dem git installiert ist, und ihn PATHmit dem Windows-Editor für Umgebungsvariablen hinzufügen .

Siehe detaillierte Anweisungen in dieser Antwort .