fix path for asdf #520
2 changed files with 7 additions and 5 deletions
|
|
@ -1363,6 +1363,8 @@ mix gettext.merge priv/gettext --on-obsolete=mark_as_obsolete
|
||||||
|
|
||||||
### 3.13 Task Runner: Just
|
### 3.13 Task Runner: Just
|
||||||
|
|
||||||
|
The `Justfile` prepends `~/.asdf/shims`, `~/.asdf/bin`, and `~/.asdf` to `PATH` for all recipes (`set export := true`), so `mix` / `elixir` resolve from `.tool-versions` without shell init. The caller's `PATH` is kept (e.g. Homebrew `asdf`, Docker). Run `asdf install` once per machine; no extra `source` is required for `just run`.
|
||||||
|
|
||||||
**Common Commands:**
|
**Common Commands:**
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
|
|
|
||||||
10
Justfile
10
Justfile
|
|
@ -1,11 +1,11 @@
|
||||||
set dotenv-load := true
|
set dotenv-load := true
|
||||||
set export := true
|
set export := true
|
||||||
|
|
||||||
# Non-interactive shells do not source .bashrc,
|
# Prepend asdf paths so recipes work without sourcing ~/.asdf/asdf.sh in the shell.
|
||||||
# PATH includes asdf shims so that mix / elixir / iex resolve without per-shell
|
# Caller PATH is preserved (Homebrew asdf, docker CLI, etc.). See CODE_GUIDELINES §3.13.
|
||||||
# `source ~/.asdf/asdf.sh`. Recipes inherit this via `set export := true`.
|
home := env_var("HOME")
|
||||||
home := env_var('HOME')
|
asdf_paths := home + "/.asdf/shims:" + home + "/.asdf/bin:" + home + "/.asdf:"
|
||||||
PATH := home + "/.asdf/shims:" + home + "/.asdf:" + home + "/.local/bin:/usr/local/bin:/usr/bin:/bin"
|
PATH := asdf_paths + env_var("PATH")
|
||||||
|
|
||||||
MIX_QUIET := "1"
|
MIX_QUIET := "1"
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue