-
Notifications
You must be signed in to change notification settings - Fork 72
Development
Inspeqtor is written in Go. The following commands should get you passing tests:
brew update
brew install go
export GOPATH=~
mkdir -p ~/src/github.com/mperham
cd ~/src/github.com/mperham
git clone git://github.com/mperham/inspeqtor
cd inspeqtor
make prepare
make
If all goes well, you should see this:
ok inspeqtor 0.029s
ok inspeqtor/conf/global 0.012s
ok inspeqtor/conf/inq 0.009s
ok inspeqtor/metrics 0.032s
ok inspeqtor/services 0.048s
ok inspeqtor/util 0.006s
Here's a checklist for submitting any non-trivial pull request:
- do you have a test to verify proper behavior?
- did you update Changes.md with a one-line description and give yourself credit?
- do you need to update any wiki content once the PR has been accepted?
I make every effort to avoid dependencies. If you want to submit a pull request which would introduce a 3rd party dependency, I'd suggest you open an issue so we can discuss it first.
In order to build a cross compiled binary on OS X you need to have a linux/amd64 specific go compiler built. The following steps assume you installed go via Homebrew. If you installed it from source then substitute your install path instead.
cd /usr/local/opt/go/libexec/src
GOOS=linux GOARCH=amd64 CGO_ENABLED=0 ./make.bash --no-clean
Once the cross compiler has been built you can use make build
to output the inspeqtor binary. You may want to remove test
as a build
prerequisite if make build
refuses to run.