Skip to content

Commit 231b870

Browse files
committed
ci: manually download pinned xlings tarball (install script ignores version pin)
1 parent 3199545 commit 231b870

2 files changed

Lines changed: 15 additions & 10 deletions

File tree

.github/workflows/ci.yml

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -56,13 +56,14 @@ jobs:
5656
- name: Bootstrap mcpp via xlings
5757
env:
5858
XLINGS_NON_INTERACTIVE: '1'
59-
XLINGS_VERSION: v0.4.25
59+
XLINGS_VERSION: '0.4.25'
6060
run: |
61-
# xlings: install if not cached. The installer reads from
62-
# /dev/tty for an interactive prompt; XLINGS_NON_INTERACTIVE=1
63-
# skips that and runs `xlings self install` directly.
6461
if [ ! -x "$HOME/.xlings/subos/default/bin/xlings" ]; then
65-
curl -fsSL https://d2learn.org/xlings-install.sh | bash
62+
tarball="xlings-${XLINGS_VERSION}-linux-x86_64.tar.gz"
63+
curl -fsSL -o "/tmp/${tarball}" \
64+
"https://github.com/d2learn/xlings/releases/download/v${XLINGS_VERSION}/${tarball}"
65+
tar -xzf "/tmp/${tarball}" -C /tmp
66+
"/tmp/xlings-${XLINGS_VERSION}-linux-x86_64/subos/default/bin/xlings" self install
6667
fi
6768
export PATH="$HOME/.xlings/subos/default/bin:$PATH"
6869
xlings --version

.github/workflows/release.yml

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -95,13 +95,17 @@ jobs:
9595
- name: Bootstrap mcpp via xlings
9696
env:
9797
XLINGS_NON_INTERACTIVE: '1'
98-
# Pin xlings version to avoid broken upstream releases (e.g.
99-
# v0.4.29 shipped with empty assets). The install script
100-
# honours XLINGS_VERSION when set.
101-
XLINGS_VERSION: v0.4.25
98+
# Pin xlings to a known-good version. The upstream install
99+
# script always grabs `latest` (no version override), so we
100+
# download + self-install manually to avoid broken releases.
101+
XLINGS_VERSION: '0.4.25'
102102
run: |
103103
if [ ! -x "$HOME/.xlings/subos/default/bin/xlings" ]; then
104-
curl -fsSL https://d2learn.org/xlings-install.sh | bash
104+
tarball="xlings-${XLINGS_VERSION}-linux-x86_64.tar.gz"
105+
curl -fsSL -o "/tmp/${tarball}" \
106+
"https://github.com/d2learn/xlings/releases/download/v${XLINGS_VERSION}/${tarball}"
107+
tar -xzf "/tmp/${tarball}" -C /tmp
108+
"/tmp/xlings-${XLINGS_VERSION}-linux-x86_64/subos/default/bin/xlings" self install
105109
fi
106110
export PATH="$HOME/.xlings/subos/default/bin:$PATH"
107111
xlings --version

0 commit comments

Comments
 (0)