air-verse / air

☁️ Live reload for Go apps
GNU General Public License v3.0
16.39k stars 773 forks source link

"air -c" and "air init" can`t run #623

Closed Strke closed 4 days ago

Strke commented 5 days ago

When I use this command air init on linux, and I get error init: required argument missing.

and air -c .air.toml get error -c:command not found

Hope to find a solution, thank you!

Strke commented 4 days ago

my .bashrc like this

export GOROOT=/usr/local/go
export GOPATH=/home/gpo/go
export PATH=$PATH:$GOROOT/bin:$GOPATH/bin
export PATH=$PATH:$(go env GOPATH)/bin
alias air=`$(go env GOPATH)/bin/air`
xiantang commented 4 days ago

could u run air -v?

Strke commented 4 days ago

Thanks for your reply, I solved it. In the .bashrc

alias air=$(go env GOPATH)/bin/air