fix: install to /usr/local/bin so the requested version wins on PATH #8

Merged
David merged 2 commits from fix/install-to-usr-local-bin into main 2026-06-14 01:56:04 +02:00
Owner

Fix the action picking up a preinstalled nu instead of the requested version.

The openSUSE base runners ship a preinstalled nu in /usr/local/bin, which precedes /usr/bin on PATH. The action installed to /usr/bin, so the preinstalled copy shadowed the version just installed: a bare nu resolved to the preinstalled one in the action's output step, in the test assertion, and for downstream consumers. The visible symptom was the test reporting the runner's 0.112.2 when 0.100.0 was requested.

Install to /usr/local/bin instead, so the requested version overrides any preinstalled copy and resolves first on PATH.

Build the plugin glob from INSTALL_DIR (passed through the environment as $env.INSTALL_DIR) rather than a hardcoded /usr/bin path. This keeps $it and $nu literal inside the single-quoted nu command and resolves the existing TODO about the directory not expanding. Verified the glob and its filter run under nu 0.112.2.

Tested: sh -n parses clean.

Fix the action picking up a preinstalled nu instead of the requested version. The openSUSE base runners ship a preinstalled nu in /usr/local/bin, which precedes /usr/bin on PATH. The action installed to /usr/bin, so the preinstalled copy shadowed the version just installed: a bare `nu` resolved to the preinstalled one in the action's output step, in the test assertion, and for downstream consumers. The visible symptom was the test reporting the runner's 0.112.2 when 0.100.0 was requested. Install to /usr/local/bin instead, so the requested version overrides any preinstalled copy and resolves first on PATH. Build the plugin glob from INSTALL_DIR (passed through the environment as $env.INSTALL_DIR) rather than a hardcoded /usr/bin path. This keeps $it and $nu literal inside the single-quoted nu command and resolves the existing TODO about the directory not expanding. Verified the glob and its filter run under nu 0.112.2. Tested: sh -n parses clean.
fix: install to /usr/local/bin so the requested version wins on PATH
All checks were successful
Test / Install Nushell latest (push) Successful in 8s
Test / Install Nushell 0.100.0 (push) Successful in 12s
Test / Install Nushell 0.101.0 (pull_request) Successful in 3s
Test / Install Nushell latest (pull_request) Successful in 6s
Test / Install Nushell 0.100.0 (pull_request) Successful in 6s
Test / Install Nushell 0.101.0 (push) Successful in 15s
13be1b4ed7
Some runners (the openSUSE base) ship a preinstalled nu in /usr/local/bin, which precedes /usr/bin on PATH. Installing to /usr/bin left that preinstalled copy shadowing the requested version, so a bare `nu` (in the action's own output step, the test assertion, and for downstream consumers) resolved to the preinstalled version instead of the one just installed. The symptom was the test reporting the runner's 0.112.2 when 0.100.0 was requested.

Install to /usr/local/bin instead so the requested version overrides any preinstalled copy and resolves first. Build the plugin glob from INSTALL_DIR (passed through the environment) instead of a hardcoded /usr/bin path, which also resolves the long-standing TODO about the directory not expanding inside the single-quoted nu command.
Merge branch 'main' into fix/install-to-usr-local-bin
Some checks failed
Test / Install Nushell latest (pull_request) Failing after 2s
Test / Install Nushell 0.101.0 (push) Successful in 4s
Test / Install Nushell 0.100.0 (pull_request) Successful in 4s
Test / Install Nushell 0.100.0 (push) Successful in 6s
Test / Install Nushell 0.101.0 (pull_request) Successful in 5s
Test / Install Nushell latest (push) Failing after 6s
af3bdf8b24
David merged commit e05d9b6736 into main 2026-06-14 01:56:04 +02:00
David deleted branch fix/install-to-usr-local-bin 2026-06-14 01:56:04 +02:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
pandoras-box/action-install-nushell!8
No description provided.