fancy-git icon indicating copy to clipboard operation
fancy-git copied to clipboard

Command not found when running from script

Open r-shafi opened this issue 3 years ago • 1 comments

Everything works from the terminal, but not when running a scrip.

My script:

#!/bin/bash/

fancygit --theme-human
fancygit --disable-time
fancygit --disable-full-path 
fancygit --enable-double-line 

Output: script.sh: line 23: fancygit: command not found

r-shafi avatar Jun 23 '22 04:06 r-shafi

I suppose you are running the script by: ./<your_file>.sh or bash ./<your_file>.sh

Instead, try running the script by sourcing: . ./<your_file>.sh or source ./<your_file>.sh

Did it work? :smile:

tsadarsh avatar Jun 26 '22 13:06 tsadarsh