Repository: nvm
Issue: Alias bypassing issue in GitBash
Labels: OS: windows,shell alias clobbering,pull request wanted,shell: git bash/cygwin

<!-- Thank you for being interested in nvm! Please help us by filling out the following form if you‘re having trouble. If you have a feature request, or some other question, please feel free to clear out the form. Thanks! -->

#### Operating system and version:

Windows 11

#### `nvm debug` output:
<details>
<!-- do not delete the following blank line -->

```sh
❯ nvm debug
nvm --version: v0.39.0
$SHELL: /usr/bin/bash
$SHLVL: 1
whoami: 'trajano'
${HOME}: /c/Users/trajano
${NVM_DIR}: '${HOME}/.nvm'
${PATH}: ${HOME}/bin:/usr/local/bin:/usr/bin:/bin:/opt/bin:/c/Program Files (x86)/Common Files/Oracle/Java/javapath:/c/ProgramData/scoop/apps/zulu12/current/bin:/c/ProgramData/scoop/shims:/c/Windows/system32:/c/Windows:/c/Windows/System32/Wbem:/c/Windows/System32/WindowsPowerShell/v1.0:/c/Windows/System32/OpenSSH:/c/ProgramData/chocolatey/bin:/c/Program Files/dotnet:/c/WINDOWS/system32:/c/WINDOWS:/c/WINDOWS/System32/Wbem:/c/WINDOWS/System32/WindowsPowerShell/v1.0:/c/WINDOWS/System32/OpenSSH:/cmd:/c/Program Files (x86)/Microsoft Emulator Manager/1.0:/c/Program Files/Docker/Docker/resources/bin:/c/ProgramData/DockerDesktop/version-bin:${HOME}/scoop/apps/python/current/Scripts:${HOME}/scoop/apps/python/current/:${HOME}/scoop/apps/imagemagick/current/:${HOME}/scoop/apps/python/current:${HOME}/scoop/apps/zulu12/current/bin:${HOME}/scoop/shims:${HOME}/AppData/Local/Microsoft/WindowsApps:${HOME}/AppData/Local/Programs/Microsoft VS Code/bin:/c/Program Files (x86)/GitHub CLI:${HOME}/AppData/Local/Microsoft/WindowsApps:/usr/bin/vendor_perl:/usr/bin/core_perl
$PREFIX: ''
${NPM_CONFIG_PREFIX}: ''
$NVM_NODEJS_ORG_MIRROR: ''
$NVM_IOJS_ORG_MIRROR: ''
shell version: 'GNU bash, version 4.4.23(1)-release (x86_64-pc-msys)'
uname -a: 'MSYS_NT-10.0-22000 3.1.7-340.x86_64 2021-10-12 16:29 UTC x86_64 Msys'
checksum binary: ''
curl: not found
wget: not found
git: not found
grep: not found
awk: not found
sed: not found
cut: not found
basename: not found
rm: not found
mkdir: not found
xargs: not found
nvm current: none
which node: which: no node in (${HOME}/bin:/usr/local/bin:/usr/bin:/bin:/opt/bin:/c/Program Files (x86)/Common Files/Oracle/Java/javapath:/c/ProgramData/scoop/apps/zulu12/current/bin:/c/ProgramData/scoop/shims:/c/Windows/system32:/c/Windows:/c/Windows/System32/Wbem:/c/Windows/System32/WindowsPowerShell/v1.0:/c/Windows/System32/OpenSSH:/c/ProgramData/chocolatey/bin:/c/Program Files/dotnet:/c/WINDOWS/system32:/c/WINDOWS:/c/WINDOWS/System32/Wbem:/c/WINDOWS/System32/WindowsPowerShell/v1.0:/c/WINDOWS/System32/OpenSSH:/cmd:/c/Program Files (x86)/Microsoft Emulator Manager/1.0:/c/Program Files/Docker/Docker/resources/bin:/c/ProgramData/DockerDesktop/version-bin:${HOME}/scoop/apps/python/current/Scripts:${HOME}/scoop/apps/python/current/:${HOME}/scoop/apps/imagemagick/current/:${HOME}/scoop/apps/python/current:${HOME}/scoop/apps/zulu12/current/bin:${HOME}/scoop/shims:${HOME}/AppData/Local/Microsoft/WindowsApps:${HOME}/AppData/Local/Programs/Microsoft VS Code/bin:/c/Program Files (x86)/GitHub CLI:${HOME}/AppData/Local/Microsoft/WindowsApps:/usr/bin/vendor_perl:/usr/bin/core_perl)
which iojs: which: no iojs in (${HOME}/bin:/usr/local/bin:/usr/bin:/bin:/opt/bin:/c/Program Files (x86)/Common Files/Oracle/Java/javapath:/c/ProgramData/scoop/apps/zulu12/current/bin:/c/ProgramData/scoop/shims:/c/Windows/system32:/c/Windows:/c/Windows/System32/Wbem:/c/Windows/System32/WindowsPowerShell/v1.0:/c/Windows/System32/OpenSSH:/c/ProgramData/chocolatey/bin:/c/Program Files/dotnet:/c/WINDOWS/system32:/c/WINDOWS:/c/WINDOWS/System32/Wbem:/c/WINDOWS/System32/WindowsPowerShell/v1.0:/c/WINDOWS/System32/OpenSSH:/cmd:/c/Program Files (x86)/Microsoft Emulator Manager/1.0:/c/Program Files/Docker/Docker/resources/bin:/c/ProgramData/DockerDesktop/version-bin:${HOME}/scoop/apps/python/current/Scripts:${HOME}/scoop/apps/python/current/:${HOME}/scoop/apps/imagemagick/current/:${HOME}/scoop/apps/python/current:${HOME}/scoop/apps/zulu12/current/bin:${HOME}/scoop/shims:${HOME}/AppData/Local/Microsoft/WindowsApps:${HOME}/AppData/Local/Programs/Microsoft VS Code/bin:/c/Program Files (x86)/GitHub CLI:${HOME}/AppData/Local/Microsoft/WindowsApps:/usr/bin/vendor_perl:/usr/bin/core_perl)
which npm: which: no npm in (${HOME}/bin:/usr/local/bin:/usr/bin:/bin:/opt/bin:/c/Program Files (x86)/Common Files/Oracle/Java/javapath:/c/ProgramData/scoop/apps/zulu12/current/bin:/c/ProgramData/scoop/shims:/c/Windows/system32:/c/Windows:/c/Windows/System32/Wbem:/c/Windows/System32/WindowsPowerShell/v1.0:/c/Windows/System32/OpenSSH:/c/ProgramData/chocolatey/bin:/c/Program Files/dotnet:/c/WINDOWS/system32:/c/WINDOWS:/c/WINDOWS/System32/Wbem:/c/WINDOWS/System32/WindowsPowerShell/v1.0:/c/WINDOWS/System32/OpenSSH:/cmd:/c/Program Files (x86)/Microsoft Emulator Manager/1.0:/c/Program Files/Docker/Docker/resources/bin:/c/ProgramData/DockerDesktop/version-bin:${HOME}/scoop/apps/python/current/Scripts:${HOME}/scoop/apps/python/current/:${HOME}/scoop/apps/imagemagick/current/:${HOME}/scoop/apps/python/current:${HOME}/scoop/apps/zulu12/current/bin:${HOME}/scoop/shims:${HOME}/AppData/Local/Microsoft/WindowsApps:${HOME}/AppData/Local/Programs/Microsoft VS Code/bin:/c/Program Files (x86)/GitHub CLI:${HOME}/AppData/Local/Microsoft/WindowsApps:/usr/bin/vendor_perl:/usr/bin/core_perl)
npm config get prefix: bash: npm: command not found
npm root -g: bash: npm: command not found
```
</details>

#### `nvm ls` output:
<details>
<!-- do not delete the following blank line -->

```sh
            N/A
iojs -> N/A (default)
node -> stable (-> N/A) (default)
unstable -> N/A (default)
```
</details>

#### How did you install `nvm`?
<!-- (e.g. install script in readme, Homebrew) -->
```
❯ curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.0/install.sh | bash
=> Downloading nvm from git to '/c/Users/trajano/.nvm'
=> Cloning into 'C:/Users/trajano/.nvm'...
remote: Enumerating objects: 349, done.
remote: Counting objects: 100% (349/349), done.
remote: Compressing objects: 100% (298/298), done.
Recei                           )
Receiving objects: 100% (349/349), 201.96 KiB | 1.22 MiB/s, done.
Resolving deltas: 100% (39/39), done.
* (HEAD detached at FETCH_HEAD)
  master
=> Compressing and cleaning up git repository

=> nvm source string already in /c/Users/trajano/.bash_profile
=> bash_completion source string already in /c/Users/trajano/.bash_profile
=> Close and reopen your terminal to start using nvm or run the following to use it now:

export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"  # This loads nvm
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion"  # This loads nvm bash_completion
```

#### What steps did you perform?

#### What happened?

it can't find `curl` or `wget`

#### What did you expect to happen?

#### Is there anything in any of your profile files that modifies the `PATH`?
<!--  (e.g. `.bashrc`, `.bash_profile`, `.zshrc`, etc) -->

<!-- Please remove the following section if it does not apply to you -->
#### If you are having installation issues, or getting "N/A", what does `curl -I --compressed -v https://nodejs.org/dist/` print out?
<details>
<!-- do not delete the following blank line -->

```sh

```
</details>