Question

When I launch an EC-2 instance and type git init, gitbash says "-bash: git: command not found" why? how can I fix this?

  • Posted March 24, 2020
  • Git

“-bash: git: command not found” using gitbash

Subscribe
Share

Submit an answer
You can type!ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Accepted Answer

Hi @towanimaria,

It seems git is not installed and as such you’ll need to install it.

If you are on a CentOS OS, you can use

yum install git

If it’s Ubuntu, use

apt install git

That’s it, you should be good to go.

Regards, KDSys