<commit_before>language: go

go:
  - 1.6
  - 1.7

env:
  global:
    - secure: "<KEY>
    - PACKAGE_VERSION: 0.0.17
    - REPO_NAME: shingetsu-gou
    - CGO_ENABLED:1 

gobuild_args: -ldflags "-X cfg.VERSION= ${PACKAGE_VERSION}"

before_install:
- sudo apt-get update
- sudo apt-get install -y automake autogen build-essential ca-certificates                    \
    gcc-5-arm-linux-gnueabi g++-5-arm-linux-gnueabi libc6-dev-armel-cross                \
    gcc-5-arm-linux-gnueabihf g++-5-arm-linux-gnueabihf libc6-dev-armhf-cross            \
    gcc-5-aarch64-linux-gnu g++-5-aarch64-linux-gnu libc6-dev-arm64-cross                \
    gcc-5-multilib g++-5-multilib gcc-mingw-w64 g++-mingw-w64 clang llvm-dev             \
    libtool libxml2-dev uuid-dev libssl-dev swig pkg-config patch          \
    make xz-utils cpio wget zip unzip p7zip  bzr texinfo help2man       --no-install-recommends
- go get github.com/axw/gocov/gocov
- go get github.com/alecthomas/gometalinter
- go get github.com/mattn/goveralls
- go get -u github.com/jteeuwen/go-bindata/...
- if ! go get code.google.com/p/go.tools/cmd/cover; then go get golang.org/x/tools/cmd/cover; fi
- export PATH=$PATH:$GOPATH/bin
- gometalinter --install --update
- go-bindata -o util/bindata.go -pkg util www/... file/... gou_template/...

script:
- go test -v -covermode=count -coverprofile=coverage.out
#- ! gometalinter --deadline=1000s ./... 2>&1 | read

after_script:
- goveralls -coverprofile=coverage.out -service=travis-ci
- gometalinter -e bindata --deadline=1000s ./...
- if  [ ${TRAVIS_GO_VERSION} == "1.7" ]; then
  echo "Bootstrapping linux/amd64...";
  go build -o ${REPO_NAME}_linux_amd64;
  echo "Bootstrapping linux/386...";
  GOOS=linux GOARCH=386 go build -o ${REPO_NAME}_${PACKAGE_VERSION}_linux_386  ;
  echo "Bootstrapping linux/arm64...";
GOOS=linux GOARCH=arm64  CC=aarch64-linux-gnu-gcc-5 go build -o ${REPO_NAME}_${PACKAGE_VERSION}_linux_arm64;
echo "Bootstrapping windows/amd64...";
GOOS=windows GOARCH=amd64  CC=x86_64-w64-mingw32-gcc go build -o ${REPO_NAME}_${PACKAGE_VERSION}_win_amd64.exe;
echo "Bootstrapping windows/386...";
GOOS=windows GOARCH=386 CC=i686-w64-mingw32-gccgo build -o ${REPO_NAME}_${PACKAGE_VERSION}_win_386.exe;
echo "Bootstrapping darwin/amd64...";
GOOS=darwin GOARCH=amd64 CC=o64-clang go build -o ${REPO_NAME}_${PACKAGE_VERSION}_darwin_amd64;
echo "Bootstrapping darwin/386...";
GOOS=darwin GOARCH=386  CC=o32-clang go build -o ${REPO_NAME}_${PACKAGE_VERSION}_darwin_386;
gzip ${REPO_NAME}_${PACKAGE_VERSION}_linux_386;
gzip ${REPO_NAME}_${PACKAGE_VERSION}_linux_amd64;
gzip ${REPO_NAME}_${PACKAGE_VERSION}_linux_arm64;
zip ${REPO_NAME}_${PACKAGE_VERSION}_win_amd64.exe.zip  ${REPO_NAME}_${PACKAGE_VERSION}_win_amd64.exe;
zip ${REPO_NAME}_${PACKAGE_VERSION}_win_386.exe.zip  ${REPO_NAME}_${PACKAGE_VERSION}_win_386.exe;
zip ${REPO_NAME}_${PACKAGE_VERSION}_darwin_amd64.zip  ${REPO_NAME}_${PACKAGE_VERSION}_darwin_amd64;
zip ${REPO_NAME}_${PACKAGE_VERSION}_darwin_386.zip  ${REPO_NAME}_${PACKAGE_VERSION}_darwin_386;
  cd ..;
  fi

deploy:
  provider: releases
  api_key:
    secure: ${GITHUB_TOKEN}
  file:
     -  "${REPO_NAME}_linux_386.gz"
     -  "${REPO_NAME}_linux_amd64.gz"<commit_msg>travis<commit_after>language: go

go:
  - 1.6
  - 1.7

env:
  global:
    - secure: "<KEY>
    - PACKAGE_VERSION: 0.0.17
    - REPO_NAME: shingetsu-gou
    - CGO_ENABLED:1 

gobuild_args: -ldflags "-X cfg.VERSION= ${PACKAGE_VERSION}"

before_install:
- sudo apt-get update
- sudo apt-get install -y automake autogen build-essential ca-certificates                    \
    gcc-5-arm-linux-gnueabi g++-5-arm-linux-gnueabi libc6-dev-armel-cross                \
    gcc-5-arm-linux-gnueabihf g++-5-arm-linux-gnueabihf libc6-dev-armhf-cross            \
    gcc-5-aarch64-linux-gnu g++-5-aarch64-linux-gnu libc6-dev-arm64-cross                \
    gcc-5-multilib g++-5-multilib gcc-mingw-w64 g++-mingw-w64 clang llvm-dev             \
    libtool libxml2-dev uuid-dev libssl-dev swig pkg-config patch          \
    make xz-utils cpio wget zip unzip p7zip  bzr texinfo help2man       --no-install-recommends
- go get github.com/axw/gocov/gocov
- go get github.com/alecthomas/gometalinter
- go get github.com/mattn/goveralls
- go get -u github.com/jteeuwen/go-bindata/...
- if ! go get code.google.com/p/go.tools/cmd/cover; then go get golang.org/x/tools/cmd/cover; fi
- export PATH=$PATH:$GOPATH/bin
- gometalinter --install --update
- go-bindata -o util/bindata.go -pkg util www/... file/... gou_template/...

script:
- go test -v -covermode=count -coverprofile=coverage.out
#- ! gometalinter --deadline=1000s ./... 2>&1 | read

after_script:
- goveralls -coverprofile=coverage.out -service=travis-ci
- gometalinter -e bindata --deadline=1000s ./...
- if  [ ${TRAVIS_GO_VERSION} == "1.7" ]; then
  echo "Bootstrapping linux/amd64...";
  go build -o ${REPO_NAME}_linux_amd64;
  echo "Bootstrapping linux/386...";
  GOOS=linux GOARCH=386 go build -o ${REPO_NAME}_${PACKAGE_VERSION}_linux_386;
  echo "Bootstrapping linux/arm64...";
  GOOS=linux GOARCH=arm64  CC=aarch64-linux-gnu-gcc-5 go build -o ${REPO_NAME}_${PACKAGE_VERSION}_linux_arm64;
  echo "Bootstrapping windows/amd64...";
  GOOS=windows GOARCH=amd64  CC=x86_64-w64-mingw32-gcc go build -o ${REPO_NAME}_${PACKAGE_VERSION}_win_amd64.exe;
  echo "Bootstrapping windows/386...";
  GOOS=windows GOARCH=386 CC=i686-w64-mingw32-gccgo build -o ${REPO_NAME}_${PACKAGE_VERSION}_win_386.exe;
  echo "Bootstrapping darwin/amd64...";
  GOOS=darwin GOARCH=amd64 CC=o64-clang go build -o ${REPO_NAME}_${PACKAGE_VERSION}_darwin_amd64;
  echo "Bootstrapping darwin/386...";
  GOOS=darwin GOARCH=386  CC=o32-clang go build -o ${REPO_NAME}_${PACKAGE_VERSION}_darwin_386;
  gzip ${REPO_NAME}_${PACKAGE_VERSION}_linux_386;
  gzip ${REPO_NAME}_${PACKAGE_VERSION}_linux_amd64;
  gzip ${REPO_NAME}_${PACKAGE_VERSION}_linux_arm64;
  zip ${REPO_NAME}_${PACKAGE_VERSION}_win_amd64.exe.zip  ${REPO_NAME}_${PACKAGE_VERSION}_win_amd64.exe;
  zip ${REPO_NAME}_${PACKAGE_VERSION}_win_386.exe.zip  ${REPO_NAME}_${PACKAGE_VERSION}_win_386.exe;
  zip ${REPO_NAME}_${PACKAGE_VERSION}_darwin_amd64.zip  ${REPO_NAME}_${PACKAGE_VERSION}_darwin_amd64;
  zip ${REPO_NAME}_${PACKAGE_VERSION}_darwin_386.zip  ${REPO_NAME}_${PACKAGE_VERSION}_darwin_386;
  cd ..;
  fi

deploy:
  provider: releases
  api_key:
    secure: ${GITHUB_TOKEN}
  file:
     -  "${REPO_NAME}_linux_386.gz"
     -  "${REPO_NAME}_linux_amd64.gz"
{'fraction_non_alphanumeric': 0.1455843551140773, 'fraction_numerical': 0.04594133167778985, 'mean_word_length': 3.6933721777130373, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 2}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3767751', 'n_tokens_mistral': 2753, 'n_tokens_neox': 2547, 'n_words': 429}