<commit_before>machine:
  environment:
    IMPORT_PATH: "github.com/$CIRCLE_PROJECT_USERNAME/$CIRCLE_PROJECT_REPONAME"
    PRIVATE_GOPATH: "$(echo $GOPATH | sed 's/:.*$//g')" # Needed because CircleCI has two paths in the GOPATH.
    REPO_ROOT: "$PRIVATE_GOPATH/src/$IMPORT_PATH"

dependencies:
  cache_directories:
    - ~/cache
  pre:
      # Prepare directories.
      - mkdir -p ~/cache "$PRIVATE_GOPATH/src/$IMPORT_PATH"
      # Install go 1.7
      - sudo rm -rf /usr/local/go
      - cd ~/cache && if [ ! -e go1.7.5.linux-amd64.tar.gz ]; then wget https://storage.googleapis.com/golang/go1.7.5.linux-amd64.tar.gz; fi
      - cd ~/cache && sudo tar -C /usr/local -xzf go1.7.5.linux-amd64.tar.gz
      - go version
      # Install test utils
      - go get github.com/golang/dep
      - go get github.com/golang/lint/golint
  post:
    - >
      echo "export BUILD_VERSION=\"`git --git-dir=${CHECKOUT_PATH}/.git describe --always --dirty`\"" >> ~/.circlerc;
      echo "export BUILD_DATE=\"`date +%FT%T%z`\"" >> ~/.circlerc;
  override:
    # Copy repository to GOPATH.
    - rsync -azC --delete ./ "$PRIVATE_GOPATH/src/$IMPORT_PATH/"

test:
  pre:
    - cd ${REPO_ROOT} && dep ensure; exit 0
  override:
    - cd ${REPO_ROOT} && for package in `go list ./...| grep -v vendor`; do golint ${package}; done
    - cd ${REPO_ROOT} && test -z "$(gofmt -s -l . | tee /dev/stderr)"
    - cd ${REPO_ROOT} && go vet ./...
    - cd ${REPO_ROOT} && go test -cover -bench -benchmem `go list ./... | grep -v /vendor/` -v

deployment:<commit_msg>fix circleci tasks<commit_after>machine:
  environment:
    IMPORT_PATH: "github.com/$CIRCLE_PROJECT_USERNAME/$CIRCLE_PROJECT_REPONAME"
    PRIVATE_GOPATH: "$(echo $GOPATH | sed 's/:.*$//g')" # Needed because CircleCI has two paths in the GOPATH.
    REPO_ROOT: "$PRIVATE_GOPATH/src/$IMPORT_PATH"

dependencies:
  cache_directories:
    - ~/cache
  pre:
      # Prepare directories.
      - mkdir -p ~/cache "$PRIVATE_GOPATH/src/$IMPORT_PATH"
      # Install go 1.7
      - sudo rm -rf /usr/local/go
      - cd ~/cache && if [ ! -e go1.7.5.linux-amd64.tar.gz ]; then wget https://storage.googleapis.com/golang/go1.7.5.linux-amd64.tar.gz; fi
      - cd ~/cache && sudo tar -C /usr/local -xzf go1.7.5.linux-amd64.tar.gz
      - go version
      # Install test utils
      - go get github.com/golang/dep
      - go get github.com/golang/lint/golint
  post:
    - >
      echo "export BUILD_VERSION=\"`git --git-dir=${CHECKOUT_PATH}/.git describe --always --dirty`\"" >> ~/.circlerc;
      echo "export BUILD_DATE=\"`date +%FT%T%z`\"" >> ~/.circlerc;
  override:
    # Copy repository to GOPATH.
    - rsync -azC --delete ./ "$PRIVATE_GOPATH/src/$IMPORT_PATH/"

test:
  pre:
    - cd ${REPO_ROOT} && go vet ./...
    - cd ${REPO_ROOT} && golint ./...
    - cd ${REPO_ROOT} && dep ensure; exit 0
  override:
    - cd ${REPO_ROOT} && go test -cover -bench -benchmem `go list ./... | grep -v /vendor/` -v

deployment:
{'fraction_non_alphanumeric': 0.17203936206311504, 'fraction_numerical': 0.012215812690872073, 'mean_word_length': 2.447953216374269, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 13, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, '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': '6453456', 'n_tokens_mistral': 1155, 'n_tokens_neox': 1111, 'n_words': 257}