Skip to content

Commit 908e780

Browse files
authored
docs: clarify what <command> means in asdf env (#459) (#2274)
1 parent 10c0f8f commit 908e780

1 file changed

Lines changed: 9 additions & 1 deletion

File tree

docs/manage/core.md

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,15 @@ Executes the command shim for the current version.
2222
asdf env <command> [util]
2323
```
2424

25-
<!-- TODO: expand on this with example -->
25+
`<command>` is the name of a shimmed binary (for example `node`, `python`, `ruby`), not an arbitrary shell command. `asdf env` resolves the plugin and version that would handle that shim and runs `[util]` (defaults to `env`) inside the same environment, so you can inspect or invoke other tools with the plugin's `PATH` and `ASDF_*` variables already set.
26+
27+
```shell
28+
# Print the environment that `node` runs in.
29+
$ asdf env node
30+
31+
# Run `which` inside that same environment to confirm where `npm` resolves.
32+
$ asdf env node which npm
33+
```
2634

2735
## Info
2836

0 commit comments

Comments
 (0)