<commit_before>machine:
  environment:
    OS: "linux"
    ARCH: "amd64"

    GOVERSION: "1.7"
    GOPATH: "$HOME/.go_workspace"

    WORKDIR: "$GOPATH/src/github.com/$CIRCLE_PROJECT_USERNAME/$CIRCLE_PROJECT_REPONAME"

dependencies:
  pre:
    # Wipe out the default go install.
    - sudo rm -rf /usr/local/go

    # Force the wipe out of GOPATH to make sure we're not relying on
    # external dependencies.
    - rm -rf "$GOPATH"

  override:
    # Install Go
    - wget "https://storage.googleapis.com/golang/go$GOVERSION.$OS-$ARCH.tar.gz"
    - sudo tar -C /usr/local -xzf "go$GOVERSION.$OS-$ARCH.tar.gz"

    # Setup the GOPATH
    - mkdir -p "$(dirname $WORKDIR)"
    - cp -R "$HOME/$CIRCLE_PROJECT_REPONAME" "$WORKDIR"

    # Install dependencies
    - cd $WORKDIR && go get github.com/golang/lint/golint github.com/wfarner/blockcheck

test:
  override:
    - cd $WORKDIR && make ci

  post:
    # Report to codecov
    - cd $WORKDIR && bash <(curl -s https://codecov.io/bash)
<commit_msg>Automate building of Docker images (#339)<commit_after>machine:
  services:
    - docker
  environment:
    OS: "linux"
    ARCH: "amd64"
    GOVERSION: "1.7"
    GOPATH: "$HOME/.go_workspace"
    WORKDIR: "$GOPATH/src/github.com/$CIRCLE_PROJECT_USERNAME/$CIRCLE_PROJECT_REPONAME"

dependencies:
  pre:
    # Wipe out the default go install.
    - sudo rm -rf /usr/local/go

    # Force the wipe out of GOPATH to make sure we're not relying on
    # external dependencies.
    - rm -rf "$GOPATH"

  override:
    # Install Go
    - wget "https://storage.googleapis.com/golang/go$GOVERSION.$OS-$ARCH.tar.gz"
    - sudo tar -C /usr/local -xzf "go$GOVERSION.$OS-$ARCH.tar.gz"

    # Setup the GOPATH
    - mkdir -p "$(dirname $WORKDIR)"
    - cp -R "$HOME/$CIRCLE_PROJECT_REPONAME" "$WORKDIR"

    # Install dependencies
    - cd $WORKDIR && go get github.com/golang/lint/golint github.com/wfarner/blockcheck

test:
  override:
    - cd $WORKDIR && make ci

  post:
    # Report to codecov
    - cd $WORKDIR && bash <(curl -s https://codecov.io/bash)

deployment:
  docker:
    branch: master
    commands:
      - docker login -u $DOCKER_HUB_USER -p $DOCKER_HUB_PASSWD
      - DOCKER_PUSH=true DOCKER_TAG_LATEST=true DOCKER_IMAGE="infrakit/bundle" DOCKER_TAG="master-$CIRCLE_BUILD_NUM" make build-in-container build-docker

{'fraction_non_alphanumeric': 0.12899050905953408, 'fraction_numerical': 0.004745470232959448, 'mean_word_length': 2.865, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 3, 'https://': 4, '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': '6974327', 'n_tokens_mistral': 904, 'n_tokens_neox': 845, 'n_words': 201}