Git Bash / MINGW64 Compatibility #3
-
|
Git Bash / MINGW64 Compatibility ProblemWhen using Git Bash, MINGW64, or other bash terminals, you get: $ phat
bash: phat: command not foundCausePhat uses |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
SolutionsSolution 1: Use PowerShell or CMD (Recommended)Simply switch to PowerShell or Command Prompt to run Phat:
Then run your Solution 2: Create a Bash AliasAdd this to your # Phat alias for Git Bash
phat() {
powershell.exe -ExecutionPolicy Bypass -File "C:/Program Files (x86)/Phat/phat.ps1" "$@"
}Note: Adjust the path if Phat is installed elsewhere. Use forward slashes ( After adding the alias:
Now you can use Solution 3: Run via PowerShell CommandYou can run Phat directly from bash using PowerShell: powershell.exe -ExecutionPolicy Bypass -File "C:/Program Files (x86)/Phat/phat.ps1" listSolution 4: Add PowerShell Function to PATHCreate a bash function wrapper. Add to export PHAT_HOME="/c/Program Files (x86)/Phat"
alias phat='powershell.exe -NoProfile -ExecutionPolicy Bypass -File "$PHAT_HOME/phat.ps1"'Important Notes for Bash Users
Testing Your SetupAfter configuring, test with: phat --versionRelated Resources |
Beta Was this translation helpful? Give feedback.
Solutions
Solution 1: Use PowerShell or CMD (Recommended)
Simply switch to PowerShell or Command Prompt to run Phat:
Win + Xand select "Windows PowerShell" or "Terminal"Win + R, typecmd, and press EnterThen run your
phatcommands normally.Solution 2: Create a Bash Alias
Add this to your
~/.bashrcor~/.bash_profile:Note: Adjust the path if Phat is installed elsewhere. Use forward slashes (
/) instead of backslashes.After adding the alias:
source ~/.bashrcNow you can use
phatcommands in…