Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
T
telegraf-nftables
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Due to inactivity, this project is scheduled to be deleted on 2035-04-24.
Why is this scheduled?
Show more breadcrumbs
vqgroup
telegraf-nftables
Commits
a1bad378
Commit
a1bad378
authored
9 years ago
by
Cameron Sparr
Browse files
Options
Downloads
Patches
Plain Diff
Turn off GOGC for faster build time in CI
parent
73f1ed4f
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
scripts/circle-test.sh
+4
-6
4 additions, 6 deletions
scripts/circle-test.sh
with
4 additions
and
6 deletions
scripts/circle-test.sh
+
4
−
6
View file @
a1bad378
...
@@ -6,9 +6,6 @@
...
@@ -6,9 +6,6 @@
BUILD_DIR
=
$HOME
/telegraf-build
BUILD_DIR
=
$HOME
/telegraf-build
VERSION
=
`
git describe
--always
--tags
`
VERSION
=
`
git describe
--always
--tags
`
# GO_VERSION=go1.4.2
# source $HOME/.gvm/scripts/gvm
# exit_if_fail gvm use $GO_VERSION
# Executes the given statement, and exits if the command returns a non-zero code.
# Executes the given statement, and exits if the command returns a non-zero code.
function
exit_if_fail
{
function
exit_if_fail
{
...
@@ -35,7 +32,7 @@ function check_go_fmt {
...
@@ -35,7 +32,7 @@ function check_go_fmt {
function
build
{
function
build
{
echo
-n
"=>
$1
-
$2
: "
echo
-n
"=>
$1
-
$2
: "
GOOS
=
$1
GOARCH
=
$2
godep go build
-o
telegraf-
$1
-
$2
\
GOOS
=
$1
GOARCH
=
$2
godep go build
-o
telegraf-
$1
-
$2
\
-ldflags
"-X main.Version
$3
"
\
-ldflags
"-X main.Version
=
$3
"
\
./cmd/telegraf/telegraf.go
./cmd/telegraf/telegraf.go
du
-h
telegraf-
$1
-
$2
du
-h
telegraf-
$1
-
$2
}
}
...
@@ -43,6 +40,8 @@ function build {
...
@@ -43,6 +40,8 @@ function build {
# Set up the build directory, and then GOPATH.
# Set up the build directory, and then GOPATH.
exit_if_fail
mkdir
$BUILD_DIR
exit_if_fail
mkdir
$BUILD_DIR
export
GOPATH
=
$BUILD_DIR
export
GOPATH
=
$BUILD_DIR
# Turning off GOGC speeds up build times
export
GOGC
=
off
export
PATH
=
$GOPATH
/bin:
$PATH
export
PATH
=
$GOPATH
/bin:
$PATH
exit_if_fail
mkdir
-p
$GOPATH
/src/github.com/influxdb
exit_if_fail
mkdir
-p
$GOPATH
/src/github.com/influxdb
...
@@ -65,9 +64,8 @@ exit_if_fail cd $GOPATH/src/github.com/influxdb/telegraf
...
@@ -65,9 +64,8 @@ exit_if_fail cd $GOPATH/src/github.com/influxdb/telegraf
# Verify that go fmt has been run
# Verify that go fmt has been run
check_go_fmt
check_go_fmt
#
Install
the code
#
Build
the code
exit_if_fail godep go build
-v
./...
exit_if_fail godep go build
-v
./...
exit_if_fail godep go
install
-v
./...
# Run the tests
# Run the tests
exit_if_fail godep go vet ./...
exit_if_fail godep go vet ./...
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment