On MacOSX, I followed the README file, but could not use the cobra line command.
For example :
cobra init github.com/spf13/newAppName
results in :
-bash: cobra: command not found
Ok, I needed to add in the PATH : $GOPATH/bin
Am getting the same issue. what is the solution to resolve this one?
Thanks in advance.
have you mange to fix the problem? i'm getting the same error
@pruse2402 @bjarkarim if you guys still have this error, go to your home directory and edit your .bashrc (or .zshrc if you're using zsh like I do) and add your $GOPATH/bin to the list. In my case its 'GOPATH=$HOME/go' so I had to adjust my path 'PATH="entry1:entry2:$HOME/go/bin". That might explain a bit better what @mdaymard already said.
step1. gedit ~/.zshrc
step2. paste below 3 lines on file
export GOPATH=$HOME/go
export GOBIN=$GOPATH/bin
export PATH=${PATH}:$GOBIN
step3.
source ~/.zshrc
step4.
restart Terminal
Most helpful comment
step1. gedit ~/.zshrc
step2. paste below 3 lines on file
export GOPATH=$HOME/go
export GOBIN=$GOPATH/bin
export PATH=${PATH}:$GOBIN
step3.
source ~/.zshrc
step4.
restart Terminal