I would like to know if it is possible to install GitBash on MacOs, to use the git commands?
unless you have to install git directly on macOs, and use the commands from the mac terminal? This is the first time I have worked on MacOs, and I have never used a Mac PC in my life ^^
You do not have to: "Git Bash" is a Windows port of GNU bash which is a POSIX-compatible shell shipped as part of Git-for-Windows.
There are two reasons to ship bash with Git-for-Windows:
Some Git commands are still written as Unix-shell scripts, and naturally require a Unix-compatible shell to be executed; the stock shells available on Windows—cmd.exe and PowerShell—are not compatible and cannot be used for that.
The GfW creators felt it would be good to provide a familiar environment for those Git users which have prior experience with Git on platforms other than Windows.
Specifically for this GfW also ships MinTTY which is a terminal emulator — that is a program displaying a graphical window in which another piece of software expecting to work with a Unix-compatible terminal, can work (and bash is one example of such software).
This means that what you perceive as "Git Bash" is actually two programs: a Windows port of bash working inside a MinTTY window.
While MacOS is, strictly speaking, is not a Unix-compatible OS, it has certain Unix heritage, and it has native bash installed right out of the box.
So after you install Git (AFAIK, usually via Homebrew), you have full native Git experience.
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