github.com/sercand/please@v13.4.0+incompatible/.circleci/config.yml (about)

     1  version: 2
     2  jobs:
     3     build-linux:
     4       working_directory: ~/please
     5       docker:
     6         - image: thoughtmachine/please_ubuntu:20190107
     7       environment:
     8         PLZ_ARGS: "-p --profile ci -o buildconfig.ci:true"
     9       steps:
    10         - checkout
    11         - restore_cache:
    12             key: bootstrap-linux-main-{{ checksum "bootstrap.sh" }}
    13         - restore_cache:
    14             key: go-linux-main-{{ checksum "third_party/go/BUILD" }}
    15         - restore_cache:
    16             key: python-linux-main-{{ checksum "third_party/python/BUILD" }}
    17         - run:
    18             name: Bootstrap & Build
    19             command: ./bootstrap.sh --exclude no_circleci --test_results_file plz-out/results/please/test_results.xml
    20         - store_test_results:
    21             path: plz-out/results
    22         - run:
    23             name: Lint
    24             command: ./tools/misc/ci_lint.py && plz-out/bin/src/please buildify --mode=check `git ls-files | grep BUILD`
    25         - run:
    26             name: Package
    27             command: ./plz-out/bin/src/please build //package:all //tools/misc:gen_release --exclude asc -p
    28         - persist_to_workspace:
    29             root: plz-out/pkg
    30             paths:
    31               - linux_amd64/please_*.tar.*
    32               - gen_release.pex
    33               - release_signer
    34         - store_artifacts:
    35             path: plz-out/log
    36         - save_cache:
    37             key: bootstrap-linux-main-{{ checksum "bootstrap.sh" }}
    38             paths: [ ".bootstrap" ]
    39         - save_cache:
    40             key: go-linux-main-{{ checksum "third_party/go/BUILD" }}
    41             paths: [ ".plz-cache/third_party/go" ]
    42         - save_cache:
    43             key: python-linux-main-{{ checksum "third_party/python/BUILD" }}
    44             paths: [ ".plz-cache/third_party/python" ]
    45  
    46     build-linux-alt:
    47       working_directory: ~/please
    48       docker:
    49         - image: thoughtmachine/please_ubuntu_alt:20190107
    50       environment:
    51         PLZ_ARGS: "-p --profile ci"
    52         PLZ_COVER: "cover"
    53       steps:
    54         - checkout
    55         - restore_cache:
    56             key: bootstrap-linux-alt-{{ checksum "bootstrap.sh" }}
    57         - restore_cache:
    58             key: go-linux-alt-{{ checksum "third_party/go/BUILD" }}
    59         - restore_cache:
    60             key: python-linux-alt-{{ checksum "third_party/python/BUILD" }}
    61         - run:
    62             name: Bootstrap & Build
    63             command: ./bootstrap.sh --exclude no_circleci --test_results_file plz-out/results/please/test_results.xml
    64         - store_test_results:
    65             path: plz-out/results
    66         - store_artifacts:
    67             path: plz-out/log
    68         - save_cache:
    69             key: bootstrap-linux-alt-{{ checksum "bootstrap.sh" }}
    70             paths: [ ".bootstrap" ]
    71         - save_cache:
    72             key: go-linux-alt-{{ checksum "third_party/go/BUILD" }}
    73             paths: [ ".plz-cache/third_party/go" ]
    74         - save_cache:
    75             key: python-linux-alt-{{ checksum "third_party/python/BUILD" }}
    76             paths: [ ".plz-cache/third_party/python" ]
    77  
    78     build-darwin:
    79        macos:
    80          xcode: "9.0"
    81        environment:
    82          PLZ_ARGS: "-p --profile ci --exclude pip"
    83          HOMEBREW_LOGS: "~/homebrew-logs"
    84          HOMEBREW_TEMP: "~/homebrew-temp"
    85        steps:
    86         - checkout
    87         - restore_cache:
    88             key: bootstrap-darwin-go111-{{ checksum "bootstrap.sh" }}
    89         - restore_cache:
    90             key: go-darwin-go111-{{ checksum "third_party/go/BUILD" }}
    91         - restore_cache:
    92             key: python-darwin-py370-{{ checksum "third_party/python/BUILD" }}
    93         - restore_cache:
    94             key: homebrew-v1
    95         - run:
    96             name: Install deps
    97             command: brew install go nasm pkg-config && brew upgrade python
    98         - run:
    99             name: Bootstrap & Build
   100             command: ./bootstrap.sh --exclude no_circleci --test_results_file plz-out/results/please/test_results.xml
   101         - store_test_results:
   102             path: plz-out/results
   103         - store_artifacts:
   104             path: plz-out/log
   105         - run:
   106             name: Package
   107             command: ./plz-out/bin/src/please build //package:all --exclude asc --exclude deb -p
   108         - persist_to_workspace:
   109             root: plz-out/pkg
   110             paths:
   111               - darwin_amd64/please_*.tar.*
   112         - store_artifacts:
   113             path: /tmp/artifacts
   114         - save_cache:
   115             key: homebrew-v1
   116             paths: [ "/usr/local/Homebrew" ]
   117         - save_cache:
   118             key: bootstrap-darwin-go111-{{ checksum "bootstrap.sh" }}
   119             paths: [ ".bootstrap" ]
   120         - save_cache:
   121             key: go-darwin-go111-{{ checksum "third_party/go/BUILD" }}
   122             paths: [ ".plz-cache/third_party/go" ]
   123         - save_cache:
   124             key: python-darwin-py370-{{ checksum "third_party/python/BUILD" }}
   125             paths: [ ".plz-cache/third_party/python" ]
   126  
   127     release:
   128       docker:
   129         - image: thoughtmachine/please_ubuntu:latest
   130       steps:
   131         - attach_workspace:
   132             at: /tmp/workspace
   133         - run: /tmp/workspace/gen_release.pex --github_token $GITHUB_TOKEN --signer /tmp/workspace/release_signer /tmp/workspace/linux_amd64/* /tmp/workspace/darwin_amd64/*
   134  
   135  workflows:
   136    version: 2
   137    build-all:
   138      jobs:
   139        - build-linux
   140        - build-linux-alt
   141        - build-darwin:
   142            requires:
   143              - build-linux
   144              - build-linux-alt
   145        - release:
   146            requires:
   147              - build-linux
   148              - build-linux-alt
   149              - build-darwin
   150            filters:
   151              branches:
   152                only: master