From 7d780661db4c1079f9484a06fb730ae5c0df64e1 Mon Sep 17 00:00:00 2001 From: Radon Rosborough Date: Thu, 14 Jan 2021 20:18:26 -0800 Subject: [PATCH] New solution that works on the free tier Let's just require some languages to be built and published locally. Easy enough. --- .circleci/config.yml | 1 - langs/ante.yaml | 3 +++ tools/ci-run.bash | 2 +- tools/generate-build-script.js | 7 +++++++ 4 files changed, 11 insertions(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index bf622c9..f30822e 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -13,7 +13,6 @@ jobs: build_and_deploy: machine: image: ubuntu-2004:202010-01 - resource_class: large steps: - checkout - run: tools/ci-bootstrap.bash diff --git a/langs/ante.yaml b/langs/ante.yaml index 2f34309..c2b413b 100644 --- a/langs/ante.yaml +++ b/langs/ante.yaml @@ -28,6 +28,9 @@ install: cp target/release/ante "${pkg}/usr/local/bin/" cp -R stdlib "${pkg}/opt/ante/" popd + # Disallow this from running in CI because compiling LLVM takes 5+ + # hours on the standard CircleCI runner. + disallowCI: true setup: | mkdir -p "$HOME/.config/ante" diff --git a/tools/ci-run.bash b/tools/ci-run.bash index f3d0600..747685c 100755 --- a/tools/ci-run.bash +++ b/tools/ci-run.bash @@ -5,4 +5,4 @@ set -euo pipefail echo "${DOCKER_PASSWORD}" | sudo -E docker login --username "${DOCKER_USERNAME}" --password-stdin make system -make publish Z=1 +make publish Z=1 CI=1 diff --git a/tools/generate-build-script.js b/tools/generate-build-script.js index 60a0792..71cc29e 100644 --- a/tools/generate-build-script.js +++ b/tools/generate-build-script.js @@ -263,6 +263,13 @@ EOF`); latest_release() { curl -sSL "https://api.github.com/repos/\$1/releases/latest" | jq -r .tag_name }`); + } + if (install && install.disallowCI) { + parts.unshift(`\ +if [[ -n "\${CI:-}" ]]; then + echo "language ${id} cannot be built in CI" >&2 + exit 1 +fi`); } parts.unshift(`\ #!/usr/bin/env bash