DanielBell99
DanielBell99

Reputation: 1957

Git Bash | bash: sudo: command not found (and others)

Goal: get Poetry working.

Using Git Bash on Windows 10 with WSL 2.

I have Anaconda3 and Git working.

pip install bash worked but did not help.


Git Bash:

(base)
HDS+dabell@PF2DCSXD MINGW64 ~
$ sudo -s
bash: sudo: command not found
(base)
HDS+dabell@PF2DCSXD MINGW64 ~
$ su -
bash: su: command not found
(base)
HDS+dabell@PF2DCSXD MINGW64 ~
$ apt update
bash: apt: command not found
(base)
HDS+dabell@PF2DCSXD MINGW64 ~
$ apt install sudo -y
bash: apt: command not found
(base)
HDS+dabell@PF2DCSXD MINGW64 ~
$ cat ~/.bashrc
. /c/Users/dabell/Anaconda3/etc/profile.d/conda.sh
(base)

These commands work in WSL 2.

Upvotes: 3

Views: 20322

Answers (1)

DanielBell99
DanielBell99

Reputation: 1957

As stated by @tkausl, Git Bash does not come with such commands.

I've also found a similar post on Stack Overflow, the top answer stating the same.

Upvotes: 3

Related Questions