Skip to content

Commit d52b6e3

Browse files
Copilotyeshan333
andcommitted
Fix mise E2E workflow PATH issues and plugin installation
Co-authored-by: yeshan333 <39296814+yeshan333@users.noreply.github.com>
1 parent 3582e1d commit d52b6e3

File tree

2 files changed

+63
-30
lines changed

2 files changed

+63
-30
lines changed
Lines changed: 24 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
1+
---
12
name: E2E tests on Darwin MacOS (mise)
23

34
on:
45
push:
56
branches: [main]
6-
pull_request:
7-
workflow_dispatch:
7+
pull_request: true
8+
workflow_dispatch: true
89
schedule:
910
# Runs at 12am UTC
1011
- cron: "0 0 * * *"
@@ -19,22 +20,32 @@ jobs:
1920
steps:
2021
- uses: actions/checkout@v4
2122

22-
- name: install mise
23-
run: |
24-
curl https://mise.run | sh
25-
echo "$HOME/.local/bin" >> $GITHUB_PATH
26-
27-
- name: install Erlang/OTP by mise with vfox-erlang plugin (Darwin)
23+
- name: install mise and Erlang/OTP via vfox-erlang plugin (Darwin)
2824
if: runner.os == 'MacOS'
2925
run: |
26+
# Install dependencies
3027
brew install --force autoconf libxslt fop wxwidgets openssl
28+
29+
# Install mise
30+
curl https://mise.run | sh
31+
32+
# Add mise to PATH for this session and install Erlang
33+
export PATH="$HOME/.local/bin:$PATH"
3134
export MAKEFLAGS=-j4
32-
mise use -g vfox:version-fox/vfox-erlang@26.2.3
33-
mise exec -- erl -version
35+
# Try the standard mise approach for vfox plugins
36+
$HOME/.local/bin/mise use -g vfox:version-fox/vfox-erlang@26.2.3 || {
37+
echo "Standard approach failed, trying manual plugin installation..."
38+
$HOME/.local/bin/mise plugin install vfox:version-fox/vfox-erlang https://github.com/version-fox/vfox-erlang/archive/${GITHUB_REF}.zip
39+
$HOME/.local/bin/mise use -g vfox:version-fox/vfox-erlang@26.2.3
40+
}
41+
42+
# Test the installation
43+
$HOME/.local/bin/mise exec -- erl -version
3444
echo "===============PATH==============="
3545
echo $PATH
3646
echo "===============PATH==============="
3747
cd assets
38-
mise exec -- erlc hello.erl
39-
mise exec -- erl -noshell -s hello hello_world -s init stop
40-
mise exec -- erl -eval 'erlang:display(shell_docs:get_doc(lists)), halt().' -noshell
48+
$HOME/.local/bin/mise exec -- erlc hello.erl
49+
$HOME/.local/bin/mise exec -- erl -noshell -s hello hello_world -s init stop
50+
$HOME/.local/bin/mise exec -- erl -eval \
51+
'erlang:display(shell_docs:get_doc(lists)), halt().' -noshell
Lines changed: 39 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
1+
---
12
name: E2E tests on Linux (mise)
23

34
on:
45
push:
56
branches: [main]
6-
pull_request:
7-
workflow_dispatch:
7+
pull_request: true
8+
workflow_dispatch: true
89
schedule:
910
# Runs at 12am UTC
1011
- cron: '0 0 * * *'
@@ -19,38 +20,59 @@ jobs:
1920
steps:
2021
- uses: actions/checkout@v4
2122

22-
- name: install mise
23-
run: |
24-
curl https://mise.run | sh
25-
echo "$HOME/.local/bin" >> $GITHUB_PATH
26-
2723
- name: prepare Erlang/OTP deps (Linux)
2824
if: matrix.os != 'ubuntu-24.04'
2925
run: |
3026
sudo apt update
31-
sudo DEBIAN_FRONTEND=noninteractive apt-get -y install build-essential autoconf m4 libncurses5-dev libwxgtk3.0-gtk3-dev libwxgtk-webview3.0-gtk3-dev libgl1-mesa-dev libglu1-mesa-dev libpng-dev libssh-dev unixodbc-dev xsltproc fop libxml2-utils libncurses-dev openjdk-11-jdk
32-
27+
sudo DEBIAN_FRONTEND=noninteractive apt-get -y install \
28+
build-essential autoconf m4 libncurses5-dev \
29+
libwxgtk3.0-gtk3-dev libwxgtk-webview3.0-gtk3-dev \
30+
libgl1-mesa-dev libglu1-mesa-dev libpng-dev libssh-dev \
31+
unixodbc-dev xsltproc fop libxml2-utils libncurses-dev \
32+
openjdk-11-jdk
33+
3334
- name: prepare Erlang/OTP deps (Linux)
3435
if: matrix.os == 'ubuntu-24.04'
3536
run: |
3637
sudo apt update
37-
sudo DEBIAN_FRONTEND=noninteractive apt-get -y install build-essential autoconf m4 libncurses5-dev libwxgtk3.2-dev libwxgtk-webview3.2-dev libgl1-mesa-dev libglu1-mesa-dev libpng-dev libssh-dev unixodbc-dev xsltproc fop libxml2-utils libncurses-dev openjdk-11-jdk
38+
sudo DEBIAN_FRONTEND=noninteractive apt-get -y install \
39+
build-essential autoconf m4 libncurses5-dev \
40+
libwxgtk3.2-dev libwxgtk-webview3.2-dev \
41+
libgl1-mesa-dev libglu1-mesa-dev libpng-dev libssh-dev \
42+
unixodbc-dev xsltproc fop libxml2-utils libncurses-dev \
43+
openjdk-11-jdk
3844
39-
- name: install Erlang/OTP by mise with vfox-erlang plugin (Linux)
45+
- name: install mise and Erlang/OTP via vfox-erlang plugin (Linux)
4046
run: |
47+
# Install mise
48+
curl https://mise.run | sh
49+
50+
# Add mise to PATH for this session
51+
export PATH="$HOME/.local/bin:$PATH"
52+
53+
# Configure mise and install Erlang (try standard approach first)
4154
export MAKEFLAGS=-j4
42-
mise use -g vfox:version-fox/vfox-erlang@26.2.3
43-
mise exec -- erl -version
55+
# Try the standard mise approach for vfox plugins
56+
$HOME/.local/bin/mise use -g vfox:version-fox/vfox-erlang@26.2.3 || {
57+
echo "Standard approach failed, trying manual plugin installation..."
58+
$HOME/.local/bin/mise plugin install vfox:version-fox/vfox-erlang https://github.com/version-fox/vfox-erlang/archive/${GITHUB_REF}.zip
59+
$HOME/.local/bin/mise use -g vfox:version-fox/vfox-erlang@26.2.3
60+
}
61+
62+
# Test the installation
63+
$HOME/.local/bin/mise exec -- erl -version
4464
echo "===============PATH==============="
4565
echo $PATH
4666
echo "===============PATH==============="
4767
cd assets
48-
mise exec -- erlc hello.erl
49-
mise exec -- erl -noshell -s hello hello_world -s init stop
50-
docs=$(mise exec -- erl -eval 'erlang:display(shell_docs:get_doc(lists)), halt().' -noshell | grep "List processing functions")
68+
$HOME/.local/bin/mise exec -- erlc hello.erl
69+
$HOME/.local/bin/mise exec -- erl -noshell -s hello hello_world -s init stop
70+
docs=$($HOME/.local/bin/mise exec -- erl -eval \
71+
'erlang:display(shell_docs:get_doc(lists)), halt().' \
72+
-noshell | grep "List processing functions")
5173
if [ -n "$docs" ]; then
5274
echo "erlang built with docs chunk"
5375
else
5476
echo "erlang does not built with docs chunk"
5577
exit 1
56-
fi
78+
fi

0 commit comments

Comments
 (0)