You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There should be a way to pass the main.go which get executed under src directory (allowing through args is better option)
Also an option to pass flags for go tags when building the project (eg: go build -tags <my_custom_tag> .)
The text was updated successfully, but these errors were encountered:
rupamkhaitan
changed the title
GO build doesnt run if i have code under src directory
go build doesnt run if i have code under src directory
Jun 23, 2020
I see below error when enabling go build in .pre-commit-config.yaml
go-build..................................................Failed
hook id: go-build
exit code: 1
go: warning: "./..." matched no packages
go: cannot find main module, but found .git/config in /Users/myspace/code_dir/
to create a module there, run:
go mod init
go: warning: "./..." matched no packages
go: cannot find main module, but found .git/config in /Users/myspace/code_dir/
to create a module there, run:
go mod init
There should be a way to pass the main.go which get executed under src directory (allowing through args is better option)
Also an option to pass flags for go tags when building the project (eg: go build -tags <my_custom_tag> .)
https://golang.org/pkg/go/build/
The text was updated successfully, but these errors were encountered: