1.18 需要先执行 `go mod init` 否则运行不起来
1.18 需要先执行 go mod init
否则运行不起来。
$ air
__ _ ___
/ /\ | | | |_)
/_/--\ |_| |_| \_ , built with Go
watching .
!exclude tmp
building...
go: cannot find main module, but found .git/config in /home/wanger/code/go/src/wangdeer/goblog
to create a module there, run:
go mod init
failed to build, error: exit status 1
^Ccleaning...
see you again~
项目问题都没人解决,特别对我门这种初学这个的人不友好,查到烦了