Cannot get source to build due to everything being in main package
ryan-berger opened this issue · 3 comments
I have downloaded the source, and I wanted to see if I could build it (go get github.com/alash3al/sqler && cd ~/go/src/github.com/alash3al/sqler && go build main.go
) so that I could either Dockerize it or build from source since I am on a Mac. I wasn't able to do so as all of the constants are in different files, but under the same main which causes build errors. Is there a way I can submit a PR organizing the files better into packages and adding a MakeFile or some other way to so that not only will these errors stop popping up when building from source, but also so that the build process/install process is easier on you and the community?
What is the issue in "everything" being in the main package?
to build it, just do this:
# download and install
go get github.com/alash3al/sqler
# run
sqler --help
to build it manually (after go get
)
cd $GOPATH/src/github.com/alash3al/sqler
go build .
Regarding the docker build, there will a docker image available today
Oh, I guess I always thought that it was more idiomatic to do go build main.go
rather than a go build .
. I could be totally wrong, I generally work solo on all of my Go projects as work has never allowed me to use Go, so I just use it for my personal projects. Also, awesome with the Docker image, that will be very helpful