Skip to content

Commit

Permalink
Merge pull request #85 from google/depfix
Browse files Browse the repository at this point in the history
Complete the new Build System
  • Loading branch information
josephlr committed Feb 12, 2018
2 parents aebae1a + b330463 commit 8b6cbfc
Show file tree
Hide file tree
Showing 315 changed files with 57,304 additions and 1,598 deletions.
12 changes: 9 additions & 3 deletions .gitignore
@@ -1,4 +1,10 @@
fscrypt
fscrypt_image
pam_fscrypt.so
bin/fscrypt
bin/pam_fscrypt.so
bin/protoc
bin/golint
bin/protoc-gen-go
bin/goimports
bin/megacheck
bin/gocovmerge
*coverage.out
.vscode
88 changes: 72 additions & 16 deletions .travis.yml
@@ -1,21 +1,77 @@
language: go
sudo: required
go:
- 1.9.x
sudo: false
dist: trusty
go: 1.9.x

addons:
apt:
sources:
- sourceline: 'deb http://en.archive.ubuntu.com/ubuntu/ artful main universe'
packages:
- libpam0g-dev
- e2fsprogs
- protobuf-compiler
- git # Needed to stop git from getting deleted
notifications:
email: false

install:
- make travis-install
stages:
- name: build
if: type = push
- name: presubmits
if: type = pr OR branch = master OR tag IS present
- name: deploy
if: type = push AND tag IS present

script:
- make travis-script
jobs:
include:
- stage: build
install: skip
script: make

- stage: presubmits
env: Generate, Format, and Lint
install:
- wget -q https://github.com/golang/dep/releases/download/v0.4.1/dep-linux-amd64 -O /tmp/dep
- chmod a+x /tmp/dep
- make tools
script:
- /tmp/dep status
- make gen
- bin/files-changed proto
- make format
- bin/files-changed format
- make lint

- &build
env: Build and Unit Tests
install: skip
script:
- go build github.com/google/fscrypt/cmd/fscrypt
- make
- <<: *build
go: 1.8.x

- env: Integration Tests
sudo: required
addons:
apt:
sources:
- sourceline: 'deb http://en.archive.ubuntu.com/ubuntu/ artful main universe'
packages:
- e2fsprogs
install:
- go get -u github.com/mattn/goveralls
- make test-setup
script:
- make coverage.out
- goveralls -coverprofile=coverage.out -service=travis-ci

- stage: deploy
env: Release Binaries
install: skip
script: skip
before_deploy: make
deploy:
- provider: releases
api_key:
secure: TODO
file:
- bin/fscrypt
- bin/pam_fscrypt.so
skip_cleanup: true
on:
repo: google/master
branch: master
tags: true
82 changes: 77 additions & 5 deletions Gopkg.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

59 changes: 34 additions & 25 deletions Gopkg.toml
@@ -1,29 +1,38 @@
# Gopkg.toml example
#
# Refer to https://github.com/golang/dep/blob/master/docs/Gopkg.toml.md
# for detailed Gopkg.toml documentation.
#
# required = ["github.com/user/thing/cmd/thing"]
# ignored = ["github.com/user/project/pkgX", "bitbucket.org/user/project/pkgA/pkgY"]
#
# [[constraint]]
# name = "github.com/user/project"
# version = "1.0.0"
#
# [[constraint]]
# name = "github.com/user/project2"
# branch = "dev"
# source = "github.com/myfork/project2"
#
# [[override]]
# name = "github.com/x/y"
# version = "2.4.0"
#
# [prune]
# non-go = false
# go-tests = true
# unused-packages = true
# Tools required for generating, liniting, and formatting code
required = [
"github.com/golang/lint/golint",
"github.com/golang/protobuf/protoc-gen-go",
"golang.org/x/tools/cmd/goimports",
"honnef.co/go/tools/cmd/megacheck",
"github.com/wadey/gocovmerge"
]

[[constraint]]
name = "github.com/golang/lint"
branch = "lukyth/feature/ignore-vendor"
source = "github.com/lukyth/lint"

# Source dependancies
[[constraint]]
name = "github.com/golang/protobuf"
version = "1.0.0"

[[constraint]]
name = "github.com/pkg/errors"
version = "0.8.0"

[[constraint]]
name = "github.com/urfave/cli"
version = "1.20.0"

# golang.org/x/* packages are not versioned
[[constraint]]
name = "golang.org/x/crypto"
branch = "master"

[[constraint]]
name = "golang.org/x/sys"
branch = "master"

[prune]
non-go = true
Expand Down

0 comments on commit 8b6cbfc

Please sign in to comment.