mirror of
https://github.com/enso-org/enso.git
synced 2024-11-21 16:36:59 +03:00
Use Environment Files in Actions (#1218)
Updates and/or pins versions of some of the GitHub Actions that we use.
This commit is contained in:
parent
207aaaccf5
commit
0740905306
17
.github/workflows/codeql-analysis.yml
vendored
17
.github/workflows/codeql-analysis.yml
vendored
@ -10,11 +10,13 @@ on:
|
||||
- "*"
|
||||
|
||||
env:
|
||||
# Please ensure that this is in sync with graalAPIVersion in build.sbt
|
||||
# Please ensure that this is in sync with graalVersion in build.sbt
|
||||
graalVersion: 20.2.0
|
||||
javaVersion: java11
|
||||
# Please ensure that this is in sync with javaVersion in build.sbt
|
||||
javaVersion: 11
|
||||
# Please ensure that this is in sync with project/build.properties
|
||||
sbtVersion: 1.3.13
|
||||
# Please ensure that this is in sync with rustVersion in build.sbt
|
||||
rustToolchain: nightly-2019-11-04
|
||||
|
||||
jobs:
|
||||
@ -43,26 +45,27 @@ jobs:
|
||||
|
||||
# Set Up Environment
|
||||
- name: Install Rust
|
||||
uses: actions-rs/toolchain@v1
|
||||
uses: actions-rs/toolchain@v1.0.6
|
||||
with:
|
||||
toolchain: ${{ env.rustToolchain }}
|
||||
override: true
|
||||
- name: Setup conda
|
||||
uses: s-weigand/setup-conda@v1
|
||||
uses: s-weigand/setup-conda@v1.0.5
|
||||
with:
|
||||
update-conda: false
|
||||
conda-channels: anaconda, conda-forge
|
||||
- name: Install FlatBuffers Compiler
|
||||
run: conda install --freeze-installed flatbuffers=1.12.0
|
||||
- name: Setup GraalVM Environment
|
||||
uses: DeLaGuardo/setup-graalvm@2.0
|
||||
uses: ayltai/setup-graalvm@v1
|
||||
with:
|
||||
graalvm-version: ${{ env.graalVersion }}.${{ env.javaVersion }}
|
||||
graalvm-version: ${{ env.graalVersion }}
|
||||
java-version: ${{ env.javaVersion }}
|
||||
- name: Set Up SBT
|
||||
run: |
|
||||
curl --retry 4 --retry-connrefused -fsSL -o sbt.tgz https://github.com/sbt/sbt/releases/download/v${{env.sbtVersion}}/sbt-${{env.sbtVersion}}.tgz
|
||||
tar -xzf sbt.tgz
|
||||
echo ::add-path::$GITHUB_WORKSPACE/sbt/bin/
|
||||
echo $GITHUB_WORKSPACE/sbt/bin/ >> $GITHUB_PATH
|
||||
|
||||
# Caches
|
||||
- name: Cache SBT
|
||||
|
4
.github/workflows/legal-review.yml
vendored
4
.github/workflows/legal-review.yml
vendored
@ -54,7 +54,7 @@ jobs:
|
||||
-UdpIPv6
|
||||
# TODO [RW] Rust will be needed by #1187
|
||||
# - name: Install Rust
|
||||
# uses: actions-rs/toolchain@v1
|
||||
# uses: actions-rs/toolchain@v1.0.6
|
||||
# with:
|
||||
# toolchain: ${{ env.rustToolchain }}
|
||||
# override: true
|
||||
@ -69,7 +69,7 @@ jobs:
|
||||
run: |
|
||||
curl --retry 4 --retry-connrefused -fsSL -o sbt.tgz https://github.com/sbt/sbt/releases/download/v${{env.sbtVersion}}/sbt-${{env.sbtVersion}}.tgz
|
||||
tar -xzf sbt.tgz
|
||||
echo ::add-path::$GITHUB_WORKSPACE/sbt/bin/
|
||||
echo $GITHUB_WORKSPACE/sbt/bin/ >> $GITHUB_PATH
|
||||
|
||||
# Caches
|
||||
- name: Cache SBT
|
||||
|
8
.github/workflows/release-update-broken.yml
vendored
8
.github/workflows/release-update-broken.yml
vendored
@ -19,15 +19,13 @@ jobs:
|
||||
run: |
|
||||
ref=${{ github.ref }}
|
||||
tag=${ref#"refs/tags/"}
|
||||
echo ::set-env name=TAG::$tag
|
||||
echo "TAG=$tag" >> $GITHUB_ENV
|
||||
- name: Check if Broken Mark is Present
|
||||
shell: bash
|
||||
run: |
|
||||
BROKEN="::set-env name=IS_BROKEN::true"
|
||||
NOT_BROKEN="::set-env name=IS_BROKEN::false"
|
||||
curl https://api.github.com/repos/${{ github.repository }}/releases/tags/${{ env.TAG }} > release.json
|
||||
./repo/tools/ci/releases/is-broken.js release.json > url.txt && echo $BROKEN || echo $NOT_BROKEN
|
||||
echo ::set-env name=BROKEN_URL::$(cat url.txt)
|
||||
./repo/tools/ci/releases/is-broken.js release.json > url.txt && echo IS_BROKEN=true >> $GITHUB_ENV || echo IS_BROKEN=false >> $GITHUB_ENV
|
||||
echo "BROKEN_URL=$(cat url.txt)" >> $GITHUB_ENV
|
||||
- name: Prepare AWS Session
|
||||
if: env.IS_BROKEN == 'true'
|
||||
shell: bash
|
||||
|
26
.github/workflows/release.yml
vendored
26
.github/workflows/release.yml
vendored
@ -31,7 +31,7 @@ jobs:
|
||||
with:
|
||||
path: repo
|
||||
- name: Enable Developer Command Prompt (Windows)
|
||||
uses: ilammy/msvc-dev-cmd@v1.3.0
|
||||
uses: ilammy/msvc-dev-cmd@v1.4.1
|
||||
- name: Disable TCP/UDP Offloading (macOS)
|
||||
if: runner.os == 'macOS'
|
||||
shell: bash
|
||||
@ -49,12 +49,12 @@ jobs:
|
||||
Disable-NetAdapterChecksumOffload -Name * -TcpIPv4 -UdpIPv4 -TcpIPv6
|
||||
-UdpIPv6
|
||||
- name: Install Rust
|
||||
uses: actions-rs/toolchain@v1
|
||||
uses: actions-rs/toolchain@v1.0.6
|
||||
with:
|
||||
toolchain: ${{ env.rustToolchain }}
|
||||
override: true
|
||||
- name: Setup conda
|
||||
uses: s-weigand/setup-conda@v1
|
||||
uses: s-weigand/setup-conda@v1.0.5
|
||||
with:
|
||||
update-conda: true
|
||||
conda-channels: anaconda, conda-forge
|
||||
@ -75,10 +75,11 @@ jobs:
|
||||
java-version: ${{ env.javaVersion }}
|
||||
native-image: true
|
||||
- name: Set Up SBT
|
||||
shell: bash
|
||||
run: |
|
||||
curl -fsSL -o sbt.tgz https://github.com/sbt/sbt/releases/download/v${{env.sbtVersion}}/sbt-${{env.sbtVersion}}.tgz
|
||||
tar -xzf sbt.tgz
|
||||
echo ::add-path::$GITHUB_WORKSPACE/sbt/bin/
|
||||
echo $GITHUB_WORKSPACE/sbt/bin/ >> $GITHUB_PATH
|
||||
|
||||
# Caches
|
||||
- name: Cache SBT
|
||||
@ -93,7 +94,8 @@ jobs:
|
||||
|
||||
# Bootstrap
|
||||
- name: Enable Release Mode
|
||||
run: echo ::set-env name=ENSO_RELEASE_MODE::true
|
||||
shell: bash
|
||||
run: echo "ENSO_RELEASE_MODE=true" >> $GITHUB_ENV
|
||||
- name: Bootstrap the Project
|
||||
working-directory: repo
|
||||
run: |
|
||||
@ -145,7 +147,7 @@ jobs:
|
||||
run: |
|
||||
chmod +x enso
|
||||
DIST_VERSION=$(./enso version --json --only-launcher | jq -r '.version')
|
||||
echo ::set-env name=DIST_VERSION::$DIST_VERSION
|
||||
echo "DIST_VERSION=$DIST_VERSION" >> $GITHUB_ENV
|
||||
|
||||
- name: Prepare Distribution Version (Windows)
|
||||
working-directory: repo
|
||||
@ -153,7 +155,7 @@ jobs:
|
||||
shell: bash
|
||||
run: |
|
||||
DIST_VERSION=$(./enso.exe version --json --only-launcher | jq -r '.version')
|
||||
echo ::set-env name=DIST_VERSION::$DIST_VERSION
|
||||
echo "DIST_VERSION=$DIST_VERSION" >> $GITHUB_ENV
|
||||
|
||||
# Currently the only architecture supported by Github runners is amd64
|
||||
- name: Prepare Distribution Environment
|
||||
@ -166,10 +168,10 @@ jobs:
|
||||
LAUNCHER_DIST_DIR=$LAUNCHER_DIST_ROOT/enso
|
||||
ENGINE_DIST_ROOT=enso-engine-$DIST_VERSION-$DIST_OS-$DIST_ARCH
|
||||
ENGINE_DIST_DIR=$ENGINE_DIST_ROOT/enso-$DIST_VERSION
|
||||
echo ::set-env name=LAUNCHER_DIST_DIR::$LAUNCHER_DIST_DIR
|
||||
echo ::set-env name=LAUNCHER_DIST_ROOT::$LAUNCHER_DIST_ROOT
|
||||
echo ::set-env name=ENGINE_DIST_DIR::$ENGINE_DIST_DIR
|
||||
echo ::set-env name=ENGINE_DIST_ROOT::$ENGINE_DIST_ROOT
|
||||
echo "LAUNCHER_DIST_DIR=$LAUNCHER_DIST_DIR" >> $GITHUB_ENV
|
||||
echo "LAUNCHER_DIST_ROOT=$LAUNCHER_DIST_ROOT" >> $GITHUB_ENV
|
||||
echo "ENGINE_DIST_DIR=$ENGINE_DIST_DIR" >> $GITHUB_ENV
|
||||
echo "ENGINE_DIST_ROOT=$ENGINE_DIST_ROOT" >> $GITHUB_ENV
|
||||
|
||||
- name: Prepare Launcher Distribution (Common)
|
||||
working-directory: repo
|
||||
@ -297,7 +299,7 @@ jobs:
|
||||
ref=${{ github.ref }}
|
||||
DIST_VERSION=${ref#"refs/tags/enso-"}
|
||||
echo "Preparing release for $DIST_VERSION"
|
||||
echo ::set-env name=DIST_VERSION::$DIST_VERSION
|
||||
echo "DIST_VERSION=$DIST_VERSION" >> $GITHUB_ENV
|
||||
|
||||
- name: Download GraalVM for Bundles
|
||||
shell: bash
|
||||
|
14
.github/workflows/rust.yml
vendored
14
.github/workflows/rust.yml
vendored
@ -24,7 +24,7 @@ jobs:
|
||||
|
||||
# Install Tooling
|
||||
- name: Install Rust
|
||||
uses: actions-rs/toolchain@v1
|
||||
uses: actions-rs/toolchain@v1.0.6
|
||||
with:
|
||||
toolchain: ${{ env.rustToolchain }}
|
||||
override: true
|
||||
@ -47,7 +47,7 @@ jobs:
|
||||
|
||||
# Lint
|
||||
- name: Check Code
|
||||
uses: actions-rs/cargo@v1
|
||||
uses: actions-rs/cargo@v1.0.1
|
||||
with:
|
||||
command: check
|
||||
|
||||
@ -64,7 +64,7 @@ jobs:
|
||||
|
||||
# Install Tooling
|
||||
- name: Install Rust
|
||||
uses: actions-rs/toolchain@v1
|
||||
uses: actions-rs/toolchain@v1.0.6
|
||||
with:
|
||||
toolchain: ${{ env.rustToolchain }}
|
||||
override: true
|
||||
@ -87,7 +87,7 @@ jobs:
|
||||
|
||||
# Lint
|
||||
- name: Lint Code
|
||||
uses: actions-rs/cargo@v1
|
||||
uses: actions-rs/cargo@v1.0.1
|
||||
with:
|
||||
command: clippy
|
||||
|
||||
@ -106,7 +106,7 @@ jobs:
|
||||
|
||||
# Install Tooling
|
||||
- name: Install Rust
|
||||
uses: actions-rs/toolchain@v1
|
||||
uses: actions-rs/toolchain@v1.0.6
|
||||
with:
|
||||
toolchain: ${{ env.rustToolchain }}
|
||||
override: true
|
||||
@ -127,7 +127,7 @@ jobs:
|
||||
|
||||
# Tests
|
||||
- name: Test Native
|
||||
uses: actions-rs/cargo@v1
|
||||
uses: actions-rs/cargo@v1.0.1
|
||||
with:
|
||||
command: test
|
||||
|
||||
@ -144,7 +144,7 @@ jobs:
|
||||
|
||||
# Install Tooling
|
||||
- name: Install Rust
|
||||
uses: actions-rs/toolchain@v1
|
||||
uses: actions-rs/toolchain@v1.0.6
|
||||
with:
|
||||
toolchain: ${{ env.rustToolchain }}
|
||||
override: true
|
||||
|
35
.github/workflows/scala.yml
vendored
35
.github/workflows/scala.yml
vendored
@ -39,7 +39,7 @@ jobs:
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- name: Enable Developer Command Prompt (Windows)
|
||||
uses: ilammy/msvc-dev-cmd@v1.3.0
|
||||
uses: ilammy/msvc-dev-cmd@v1.4.1
|
||||
- name: Disable TCP/UDP Offloading (macOS)
|
||||
if: runner.os == 'macOS'
|
||||
shell: bash
|
||||
@ -57,12 +57,12 @@ jobs:
|
||||
Disable-NetAdapterChecksumOffload -Name * -TcpIPv4 -UdpIPv4 -TcpIPv6
|
||||
-UdpIPv6
|
||||
- name: Install Rust
|
||||
uses: actions-rs/toolchain@v1
|
||||
uses: actions-rs/toolchain@v1.0.6
|
||||
with:
|
||||
toolchain: ${{ env.rustToolchain }}
|
||||
override: true
|
||||
- name: Setup conda
|
||||
uses: s-weigand/setup-conda@v1
|
||||
uses: s-weigand/setup-conda@v1.0.5
|
||||
with:
|
||||
update-conda: false
|
||||
conda-channels: anaconda, conda-forge
|
||||
@ -83,10 +83,11 @@ jobs:
|
||||
java-version: ${{ env.javaVersion }}
|
||||
native-image: true
|
||||
- name: Set Up SBT
|
||||
shell: bash
|
||||
run: |
|
||||
curl --retry 4 --retry-connrefused -fsSL -o sbt.tgz https://github.com/sbt/sbt/releases/download/v${{env.sbtVersion}}/sbt-${{env.sbtVersion}}.tgz
|
||||
tar -xzf sbt.tgz
|
||||
echo ::add-path::$GITHUB_WORKSPACE/sbt/bin/
|
||||
echo $GITHUB_WORKSPACE/sbt/bin/ >> $GITHUB_PATH
|
||||
|
||||
# Caches
|
||||
- name: Cache SBT
|
||||
@ -112,22 +113,24 @@ jobs:
|
||||
# Tests
|
||||
- name: Setup Tests on Windows
|
||||
if: runner.os == 'Windows'
|
||||
shell: bash
|
||||
run: |
|
||||
echo '::set-env name=CI_TEST_TIMEFACTOR::2'
|
||||
echo '::set-env name=CI_TEST_FLAKY_ENABLE::true'
|
||||
echo "CI_TEST_TIMEFACTOR=2" >> $GITHUB_ENV
|
||||
echo "CI_TEST_FLAKY_ENABLE=true" >> $GITHUB_ENV
|
||||
- name: Build Base Java Extensions
|
||||
shell: bash
|
||||
run: |
|
||||
sleep 1
|
||||
sbt --no-colors std-bits/package
|
||||
- name: Build the Launcher
|
||||
shell: bash
|
||||
run: |
|
||||
sleep 1
|
||||
sbt --no-colors launcher/buildNativeImage
|
||||
# Prevents launcher/test from re-building the Native Image during
|
||||
# test run. It is built before starting the tests to conserve system
|
||||
# memory
|
||||
echo '::set-env name=LAUNCHER_NATIVE_IMAGE_TEST_SKIP_BUILD::true'
|
||||
echo "LAUNCHER_NATIVE_IMAGE_TEST_SKIP_BUILD=true" >> $GITHUB_ENV
|
||||
- name: Test Enso
|
||||
run: |
|
||||
sleep 1
|
||||
@ -176,14 +179,14 @@ jobs:
|
||||
shell: bash
|
||||
run: |
|
||||
DIST_VERSION=$(./enso version --json --only-launcher | jq -r '.version')
|
||||
echo ::set-env name=DIST_VERSION::$DIST_VERSION
|
||||
echo "DIST_VERSION=$DIST_VERSION" >> $GITHUB_ENV
|
||||
|
||||
- name: Prepare Distribution Version (Windows)
|
||||
if: runner.os == 'Windows'
|
||||
shell: bash
|
||||
run: |
|
||||
DIST_VERSION=$(./enso.exe version --json --only-launcher | jq -r '.version')
|
||||
echo ::set-env name=DIST_VERSION::$DIST_VERSION
|
||||
echo "DIST_VERSION=$DIST_VERSION" >> $GITHUB_ENV
|
||||
|
||||
# Currently the only architecture supported by Github runners is amd64
|
||||
- name: Prepare Distribution Environment
|
||||
@ -195,10 +198,10 @@ jobs:
|
||||
LAUNCHER_DIST_DIR=$LAUNCHER_DIST_ROOT/enso
|
||||
ENGINE_DIST_ROOT=enso-engine-$DIST_VERSION-$DIST_OS-$DIST_ARCH
|
||||
ENGINE_DIST_DIR=$ENGINE_DIST_ROOT/enso-$DIST_VERSION
|
||||
echo ::set-env name=LAUNCHER_DIST_DIR::$LAUNCHER_DIST_DIR
|
||||
echo ::set-env name=LAUNCHER_DIST_ROOT::$LAUNCHER_DIST_ROOT
|
||||
echo ::set-env name=ENGINE_DIST_DIR::$ENGINE_DIST_DIR
|
||||
echo ::set-env name=ENGINE_DIST_ROOT::$ENGINE_DIST_ROOT
|
||||
echo "LAUNCHER_DIST_DIR=$LAUNCHER_DIST_DIR" >> $GITHUB_ENV
|
||||
echo "LAUNCHER_DIST_ROOT=$LAUNCHER_DIST_ROOT" >> $GITHUB_ENV
|
||||
echo "ENGINE_DIST_DIR=$ENGINE_DIST_DIR" >> $GITHUB_ENV
|
||||
echo "ENGINE_DIST_ROOT=$ENGINE_DIST_ROOT" >> $GITHUB_ENV
|
||||
|
||||
- name: Prepare Launcher Distribution (Common)
|
||||
shell: bash
|
||||
@ -259,7 +262,7 @@ jobs:
|
||||
|
||||
# Publish
|
||||
- name: Publish the Engine Distribution Artifact
|
||||
uses: actions/upload-artifact@v1.0.0
|
||||
uses: actions/upload-artifact@v2
|
||||
with:
|
||||
name: ${{ env.ENGINE_DIST_ROOT }}
|
||||
path: ${{ env.ENGINE_DIST_ROOT }}
|
||||
@ -279,7 +282,7 @@ jobs:
|
||||
zip -r -m -ll "fbs-upload/fbs-schema.zip" "fbs-upload/fbs-schema/"
|
||||
- name: Publish the FlatBuffers Schemas
|
||||
if: runner.os == 'Linux'
|
||||
uses: actions/upload-artifact@v1.0.0
|
||||
uses: actions/upload-artifact@v2
|
||||
with:
|
||||
name: Engine Protocol FlatBuffers Schemas
|
||||
path: ./fbs-upload/fbs-schema.zip
|
||||
@ -290,7 +293,7 @@ jobs:
|
||||
cp ./target/scala-parser.js parser-upload
|
||||
- name: Publish the Parser JS Bundle
|
||||
if: runner.os == 'Linux'
|
||||
uses: actions/upload-artifact@v1.0.0
|
||||
uses: actions/upload-artifact@v2
|
||||
with:
|
||||
name: Parser JS Bundle
|
||||
path: ./target/scala-parser.js
|
||||
|
Loading…
Reference in New Issue
Block a user