-
Notifications
You must be signed in to change notification settings - Fork 10
Open
Description
I ran into problems using pkgxdev/dev@v1 with Elixir. The workflow fails unless I add the following workaround, which sets ERL_ROOTDIR explicitly. With this in place, Elixir runs fine:
.github/actions/elixir-setup/action.yml
name: Elixir setup
description: Setup Elixir for a given path
runs:
using: composite
steps:
- uses: pkgxdev/dev@v1
- shell: bash
run: |
unset ERL_ROOTDIR
ERL_BIN="$(command -v erl)"
ERL_BIN_REAL="$(readlink -f "$ERL_BIN")"
ERL_DIR="$(dirname "$(dirname "$ERL_BIN_REAL")")"
if [ -d "$ERL_DIR/lib/erlang" ]; then
ERL_BASE="$ERL_DIR/lib/erlang"
else
ERL_BASE="$ERL_DIR"
fi
echo "ERL_BASE=$ERL_BASE" >> "$GITHUB_ENV"
echo "ERL_ROOTDIR=$ERL_BASE" >> "$GITHUB_ENV"
.github/workflows/ci.yml
name: ci
on:
push:
branches: main
workflow_dispatch:
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
- uses: ./.github/actions/elixir-setup
- run: elixir -e "IO.puts(1 + 2)"
.pkgx.yaml
dependencies:
elixir-lang.org: =1.15.6
erlang.org: =26.1.1
Is this something that should be fixed in pkgxdev/dev@v1 itself, or is it expected that workflows need to add this step? Or does this point to something about the packages themselves?
Metadata
Metadata
Assignees
Labels
No labels