I'm trying to use git on powershell, but having trouble. I was following Miguel Grinberg pycon workshop, and he clones with git clone " " I know I can download git, and can be done with git bash. but I want to do the command on windows powershell. Can it be done outside of gitbash?
If you download and install the git client for Windows, it will work in powershell.
https://git-scm.com/download/win
For example:
PS C:\Users\joeyoung> git --version
git version 1.9.5.msysgit.1
PS C:\Users\joeyoung> git clone https://github.com/miguelgrinberg/flask-pycon2015.git
Cloning into 'flask-pycon2015'...
remote: Counting objects: 70, done.
remote: Total 70 (delta 0), reused 0 (delta 0), pack-reused 70
Unpacking objects: 100% (70/70), done.
Checking connectivity... done.
PS C:\Users\joeyoung> dir .\flask-pycon2015
Directory: C:\Users\joeyoung\flask-pycon2015
Mode LastWriteTime Length Name
---- ------------- ------ ----
d---- 31/08/2015 10:56 templates
-a--- 31/08/2015 10:56 675 .gitignore
-a--- 31/08/2015 10:56 3735 app.py
-a--- 31/08/2015 10:56 3629 guess.py
-a--- 31/08/2015 10:56 1083 LICENSE
-a--- 31/08/2015 10:56 99 README.md
-a--- 31/08/2015 10:56 112 requirements.txt
PS C:\Users\joeyoung>
If you downloaded git from https://git-scm.com/download/win, then you could choose whether to modify PATH when you installed it:

If you chose "Use Git from Git Bash only", you will not be able to use it in the powershell, unless you add X:\path-to-git-installation\cmd to your PATH manually.
Otherwise, you should have no trouble using git in powershell.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With