From d332169bcc968855848313f4bfda07d5e4d15027 Mon Sep 17 00:00:00 2001 From: Dominic Letz Date: Thu, 25 Aug 2022 11:44:03 +0200 Subject: [PATCH] Fix CI (#5) --- .github/workflows/ci.yml | 22 +++++++++++----------- app/.tool-versions | 2 -- 2 files changed, 11 insertions(+), 13 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e8cb781..c137308 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -9,18 +9,16 @@ jobs: steps: - uses: actions/checkout@v1 - - name: Install Elixir + - name: Install asdf, erlang, elixir run: | - wget https://packages.erlang-solutions.com/erlang-solutions_2.0_all.deb && sudo dpkg -i erlang-solutions_2.0_all.deb - sudo apt-get update - sudo apt-get install esl-erlang inotify-tools - mkdir $HOME/elixir && cd $HOME/elixir - wget https://github.com/elixir-lang/elixir/releases/download/v1.11.4/Precompiled.zip - unzip Precompiled.zip - echo "$HOME/elixir/bin" >> $GITHUB_PATH + sudo apt install curl git + git clone https://github.com/asdf-vm/asdf.git $HOME/.asdf --branch v0.10.2 + . $HOME/.asdf/asdf.sh + asdf plugin-add erlang + asdf plugin-add elixir - - name: Set up hex & rebar - run: | + cd app + asdf install mix local.hex --force mix local.rebar --force @@ -30,7 +28,9 @@ jobs: java-version: 11 - name: Build with Gradle - run: bash ./gradlew assembleDebug --stacktrace + run: | + . $HOME/.asdf/asdf.sh + ./gradlew assembleDebug --stacktrace - name: Upload APK uses: actions/upload-artifact@v1 diff --git a/app/.tool-versions b/app/.tool-versions index 4654fca..4cca4f7 100644 --- a/app/.tool-versions +++ b/app/.tool-versions @@ -1,4 +1,2 @@ -Erlang 25.0.4 erlang 25.0.4 -Elixir 1.13.4-otp-25 elixir 1.13.4-otp-25