Close #349 - Upgrade libraries and sbt plugins #177
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: "[GraalVM] Build All" | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
branches: | |
- main | |
env: | |
CLI_SCALA_VERSION: "3.2.2" | |
CLI_SCALA_BINARY_VERSION: "3" | |
GRAALVM_JAVA_VERSION: "adopt@1.11" | |
GRAALVM_BIN_DIR_NAME: "native-image" | |
PROJECT_NAME: "maven2sbt" | |
jobs: | |
graalvm_build: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: [ubuntu-latest, macos-latest] | |
run-binary: [maven2sbt-cli, maven2sbt-cli.exe] | |
exclude: | |
- os: ubuntu-latest | |
run-binary: maven2sbt-cli.exe | |
- os: macos-latest | |
run-binary: maven2sbt-cli.exe | |
- os: windows-latest | |
run-binary: maven2sbt-cli | |
steps: | |
- uses: actions/checkout@v2.3.4 | |
- uses: olafurpg/setup-scala@v10 | |
with: | |
java-version: ${{ env.GRAALVM_JAVA_VERSION }} | |
- name: Cache SBT | |
uses: actions/cache@v2 | |
with: | |
path: | | |
~/.ivy2/cache | |
~/.cache/coursier | |
~/.sbt | |
key: ${{ runner.os }}-sbt-${{ env.CLI_SCALA_BINARY_VERSION }}-${{ hashFiles('**/*.sbt') }}-${{ hashFiles('**/build.properties') }} | |
restore-keys: | | |
${{ runner.os }}-sbt-${{ env.CLI_SCALA_BINARY_VERSION }}- | |
- name: "GraalVM Build for Scala ${{ env.CLI_SCALA_VERSION }} - ${{ github.run_number }}" | |
env: | |
CURRENT_BRANCH_NAME: ${{ github.ref }} | |
RUN_ID: ${{ github.run_id }} | |
RUN_NUMBER: ${{ github.run_number }} | |
run: | | |
sbt \ | |
-J-Xmx2048m \ | |
++${{ env.CLI_SCALA_VERSION }}! \ | |
clean \ | |
test \ | |
nativeImage | |
rm -f modules/${{ env.PROJECT_NAME }}-*/target/scala-*/*.jar | |
ls -lGh modules/${{ env.PROJECT_NAME }}-cli/target/${{ env.GRAALVM_BIN_DIR_NAME }}/ | |
sh -c "modules/${{ env.PROJECT_NAME }}-cli/target/${{ env.GRAALVM_BIN_DIR_NAME }}/${{ matrix.run-binary }} --version" | |
sh -c "modules/${{ env.PROJECT_NAME }}-cli/target/${{ env.GRAALVM_BIN_DIR_NAME }}/${{ matrix.run-binary }} --help" | |
sh -c "modules/${{ env.PROJECT_NAME }}-cli/target/${{ env.GRAALVM_BIN_DIR_NAME }}/${{ matrix.run-binary }} print --help" | |
sh -c "modules/${{ env.PROJECT_NAME }}-cli/target/${{ env.GRAALVM_BIN_DIR_NAME }}/${{ matrix.run-binary }} file --help" | |
graalvm_build_windows: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: [windows-latest] | |
run-binary: [maven2sbt-cli] | |
steps: | |
- name: Configure git | |
run: "git config --global core.autocrlf false" | |
shell: bash | |
- uses: actions/checkout@v2.3.4 | |
- uses: olafurpg/setup-scala@v10 | |
with: | |
java-version: ${{ env.GRAALVM_JAVA_VERSION }} | |
- uses: ilammy/msvc-dev-cmd@v1 | |
- name: Cache SBT | |
uses: actions/cache@v2 | |
with: | |
path: | | |
~/.ivy2/cache | |
~/.cache/coursier | |
~/.sbt | |
key: ${{ runner.os }}-sbt-${{ env.CLI_SCALA_BINARY_VERSION }}-${{ hashFiles('**/*.sbt') }}-${{ hashFiles('**/build.properties') }} | |
restore-keys: | | |
${{ runner.os }}-sbt-${{ env.CLI_SCALA_BINARY_VERSION }}- | |
- name: "GraalVM Build for Scala ${{ env.CLI_SCALA_VERSION }} - ${{ github.run_number }}" | |
shell: bash | |
env: | |
CURRENT_BRANCH_NAME: ${{ github.ref }} | |
RUN_ID: ${{ github.run_id }} | |
RUN_NUMBER: ${{ github.run_number }} | |
run: | | |
sbt \ | |
-J-Xmx2048m \ | |
++${{ env.CLI_SCALA_VERSION }}! \ | |
clean \ | |
test \ | |
nativeImage | |
rm -f modules/${{ env.PROJECT_NAME }}-*/target/scala-*/*.jar | |
ls -lGh modules/${{ env.PROJECT_NAME }}-cli/target/${{ env.GRAALVM_BIN_DIR_NAME }}/ | |
sh -c "modules/${{ env.PROJECT_NAME }}-cli/target/${{ env.GRAALVM_BIN_DIR_NAME }}/${{ matrix.run-binary }} --version" | |
sh -c "modules/${{ env.PROJECT_NAME }}-cli/target/${{ env.GRAALVM_BIN_DIR_NAME }}/${{ matrix.run-binary }} --help" | |
sh -c "modules/${{ env.PROJECT_NAME }}-cli/target/${{ env.GRAALVM_BIN_DIR_NAME }}/${{ matrix.run-binary }} print --help" | |
sh -c "modules/${{ env.PROJECT_NAME }}-cli/target/${{ env.GRAALVM_BIN_DIR_NAME }}/${{ matrix.run-binary }} file --help" |