2015-03-24 19:26:31 +00:00
|
|
|
# http://docs.travis-ci.com/user/languages/go/
|
|
|
|
language: go
|
2016-02-09 21:39:07 +00:00
|
|
|
|
2018-10-02 22:55:19 +00:00
|
|
|
go: 1.11.1
|
2016-02-09 21:39:07 +00:00
|
|
|
|
2016-01-14 17:30:56 +00:00
|
|
|
os:
|
|
|
|
- linux
|
2016-02-09 21:39:07 +00:00
|
|
|
|
2016-02-11 08:55:03 +00:00
|
|
|
env:
|
|
|
|
global:
|
all: use Go Modules instead of Glide
Since we are now building on Go 1.11 (as of 074a2d4f (all: use Go 1.11
in CI, 2018-08-28)) and Go 1.11 supports Go Modules [1], let's stop
using Glide, and begin using Go Modules.
This involves a few things:
* Teach the Makefile how to build go.sum files instead of glide.lock
files.
* Teach continuous integration services to build Git LFS in a
non-$GOPATH environment, since (without setting GO111MODULE=on
explicitly, which we choose not to do), this will break compiling
Git LFS, because Go 1.11 will ignore modules present in a Go
checkout beneath $GOPATH.
* In order to do the above, let's also make sure that we are
un-setting $GOCACHE in the environment, as this causes Go to work
without modules support [2].
* Because we're no longer building in a `$GOPATH`-based location,
let's instruct the CircleCI base image to archive the new location,
too.
* Similarly, teach the RPM spec to build in a non-$GOPATH location.
* By contrast, since we use dh_golang to build git-lfs binaries on
Debian, let's wait until the upstream dh_golang package is released
with support for Go 1.11 module support explicitly. Therefore, force
GO111MODULE to be on so that we can build a copy of Git LFS whose
checkout is within a $GOPATH.
Although the go.mod versions match the glide.yaml ones, the diff
attached is large because Go Modules do not vendor `_test.go` files,
whereas Glide does.
[1]: https://golang.org/doc/go1.11#modules
[2]: `GOCACHE=on` will be deprecated in Go 1.12, so this change makes
sense for that reason, too.
Co-authored-by: brian m. carlson <bk2204@github.com>
2018-08-28 20:53:57 +00:00
|
|
|
- GIT_LFS_SRC_DIR="$HOME/src/git-lfs"
|
2016-02-11 08:55:03 +00:00
|
|
|
- GIT_LFS_TEST_DIR="$HOME/git-lfs-tests"
|
2016-07-11 14:51:18 +00:00
|
|
|
- GIT_SOURCE_REPO="https://github.com/git/git.git"
|
2017-06-23 22:32:03 +00:00
|
|
|
- GIT_EARLIEST_SUPPORTED_VERSION="v2.0.0
|
2016-11-08 10:58:46 +00:00
|
|
|
- GIT_LATEST_SOURCE_BRANCH="master"
|
2017-08-10 23:32:53 +00:00
|
|
|
- GIT_ASKPASS=""
|
2016-02-11 08:55:03 +00:00
|
|
|
|
2016-02-09 21:39:07 +00:00
|
|
|
matrix:
|
2016-04-11 17:00:37 +00:00
|
|
|
fast_finish: true
|
2016-02-09 21:39:07 +00:00
|
|
|
include:
|
2016-11-08 10:58:46 +00:00
|
|
|
- env: git-latest-master-from-source
|
2016-07-11 14:51:18 +00:00
|
|
|
os: linux
|
|
|
|
before_script:
|
|
|
|
- >
|
all: use Go Modules instead of Glide
Since we are now building on Go 1.11 (as of 074a2d4f (all: use Go 1.11
in CI, 2018-08-28)) and Go 1.11 supports Go Modules [1], let's stop
using Glide, and begin using Go Modules.
This involves a few things:
* Teach the Makefile how to build go.sum files instead of glide.lock
files.
* Teach continuous integration services to build Git LFS in a
non-$GOPATH environment, since (without setting GO111MODULE=on
explicitly, which we choose not to do), this will break compiling
Git LFS, because Go 1.11 will ignore modules present in a Go
checkout beneath $GOPATH.
* In order to do the above, let's also make sure that we are
un-setting $GOCACHE in the environment, as this causes Go to work
without modules support [2].
* Because we're no longer building in a `$GOPATH`-based location,
let's instruct the CircleCI base image to archive the new location,
too.
* Similarly, teach the RPM spec to build in a non-$GOPATH location.
* By contrast, since we use dh_golang to build git-lfs binaries on
Debian, let's wait until the upstream dh_golang package is released
with support for Go 1.11 module support explicitly. Therefore, force
GO111MODULE to be on so that we can build a copy of Git LFS whose
checkout is within a $GOPATH.
Although the go.mod versions match the glide.yaml ones, the diff
attached is large because Go Modules do not vendor `_test.go` files,
whereas Glide does.
[1]: https://golang.org/doc/go1.11#modules
[2]: `GOCACHE=on` will be deprecated in Go 1.12, so this change makes
sense for that reason, too.
Co-authored-by: brian m. carlson <bk2204@github.com>
2018-08-28 20:53:57 +00:00
|
|
|
cd "$GIT_LFS_SRC_DIR";
|
2016-07-11 14:51:18 +00:00
|
|
|
git clone $GIT_SOURCE_REPO git-source;
|
|
|
|
cd git-source;
|
2016-11-08 10:58:46 +00:00
|
|
|
git checkout $GIT_LATEST_SOURCE_BRANCH;
|
2016-10-24 06:13:49 +00:00
|
|
|
make --jobs=2;
|
|
|
|
make install;
|
|
|
|
cd ..;
|
2016-11-08 10:58:46 +00:00
|
|
|
- env: git-earliest-supported-version-from-source
|
|
|
|
os: linux
|
|
|
|
before_script:
|
|
|
|
- >
|
all: use Go Modules instead of Glide
Since we are now building on Go 1.11 (as of 074a2d4f (all: use Go 1.11
in CI, 2018-08-28)) and Go 1.11 supports Go Modules [1], let's stop
using Glide, and begin using Go Modules.
This involves a few things:
* Teach the Makefile how to build go.sum files instead of glide.lock
files.
* Teach continuous integration services to build Git LFS in a
non-$GOPATH environment, since (without setting GO111MODULE=on
explicitly, which we choose not to do), this will break compiling
Git LFS, because Go 1.11 will ignore modules present in a Go
checkout beneath $GOPATH.
* In order to do the above, let's also make sure that we are
un-setting $GOCACHE in the environment, as this causes Go to work
without modules support [2].
* Because we're no longer building in a `$GOPATH`-based location,
let's instruct the CircleCI base image to archive the new location,
too.
* Similarly, teach the RPM spec to build in a non-$GOPATH location.
* By contrast, since we use dh_golang to build git-lfs binaries on
Debian, let's wait until the upstream dh_golang package is released
with support for Go 1.11 module support explicitly. Therefore, force
GO111MODULE to be on so that we can build a copy of Git LFS whose
checkout is within a $GOPATH.
Although the go.mod versions match the glide.yaml ones, the diff
attached is large because Go Modules do not vendor `_test.go` files,
whereas Glide does.
[1]: https://golang.org/doc/go1.11#modules
[2]: `GOCACHE=on` will be deprecated in Go 1.12, so this change makes
sense for that reason, too.
Co-authored-by: brian m. carlson <bk2204@github.com>
2018-08-28 20:53:57 +00:00
|
|
|
cd "$GIT_LFS_SRC_DIR";
|
2016-11-08 10:58:46 +00:00
|
|
|
git clone $GIT_SOURCE_REPO git-source;
|
|
|
|
cd git-source;
|
|
|
|
git checkout $GIT_EARLIEST_SUPPORTED_VERSION;
|
|
|
|
make --jobs=2;
|
|
|
|
make install;
|
|
|
|
cd ..;
|
2016-02-09 21:39:07 +00:00
|
|
|
- env: git-latest
|
|
|
|
os: linux
|
|
|
|
addons:
|
|
|
|
apt:
|
|
|
|
sources:
|
|
|
|
- git-core
|
|
|
|
packages:
|
|
|
|
- git
|
|
|
|
|
2015-06-15 13:59:39 +00:00
|
|
|
before_install:
|
2016-02-11 08:54:12 +00:00
|
|
|
- >
|
all: use Go Modules instead of Glide
Since we are now building on Go 1.11 (as of 074a2d4f (all: use Go 1.11
in CI, 2018-08-28)) and Go 1.11 supports Go Modules [1], let's stop
using Glide, and begin using Go Modules.
This involves a few things:
* Teach the Makefile how to build go.sum files instead of glide.lock
files.
* Teach continuous integration services to build Git LFS in a
non-$GOPATH environment, since (without setting GO111MODULE=on
explicitly, which we choose not to do), this will break compiling
Git LFS, because Go 1.11 will ignore modules present in a Go
checkout beneath $GOPATH.
* In order to do the above, let's also make sure that we are
un-setting $GOCACHE in the environment, as this causes Go to work
without modules support [2].
* Because we're no longer building in a `$GOPATH`-based location,
let's instruct the CircleCI base image to archive the new location,
too.
* Similarly, teach the RPM spec to build in a non-$GOPATH location.
* By contrast, since we use dh_golang to build git-lfs binaries on
Debian, let's wait until the upstream dh_golang package is released
with support for Go 1.11 module support explicitly. Therefore, force
GO111MODULE to be on so that we can build a copy of Git LFS whose
checkout is within a $GOPATH.
Although the go.mod versions match the glide.yaml ones, the diff
attached is large because Go Modules do not vendor `_test.go` files,
whereas Glide does.
[1]: https://golang.org/doc/go1.11#modules
[2]: `GOCACHE=on` will be deprecated in Go 1.12, so this change makes
sense for that reason, too.
Co-authored-by: brian m. carlson <bk2204@github.com>
2018-08-28 20:53:57 +00:00
|
|
|
mkdir -p "$(dirname "$GIT_LFS_SRC_DIR")";
|
|
|
|
mv "$TRAVIS_BUILD_DIR" "$GIT_LFS_SRC_DIR";
|
|
|
|
export TRAVIS_BUILD_DIR="$GIT_LFS_SRC_DIR";
|
2016-02-09 21:39:07 +00:00
|
|
|
|
|
|
|
install: true
|
|
|
|
|
|
|
|
script: script/cibuild
|
|
|
|
|
|
|
|
notifications:
|
|
|
|
email: false
|