Skip to content

Commit

Permalink
added directions to use run command.
Browse files Browse the repository at this point in the history
  • Loading branch information
tristanisham committed Nov 14, 2024
1 parent c14087e commit b9a7353
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -234,6 +234,33 @@ zvm clean

Use `clean` to remove build artifacts (Good if you're on Windows).

## Run installed version of Zig without switching your default

If you want to run a version of Zig without setting it as your default, the new `run` command is your friend.

```sh
zig version
# 0.13.0

zvm run 0.11.0 version
# 0.11.0

zig version
# 0.13.0
```
This can be helpful if you want to test your project on a newer version of Zig without having to switch between bins, or on alternative flavor of Zig.

## How to use with alternative VMUs
Make sure you switch your VMU before using `run`.

```sh
zvm vmu zig mach
run mach-latest version
# 0.14.0-dev.1911+3bf89f55c
```

If you would like to run the currently set Zig, please keep using the standard `zig` command.

## Set Version Map Source

ZVM lets choose your vendor for Zig and ZLS. This is great if your company hosts it's own internal fork of Zig, you prefer a different flavor of the language, like Mach.
Expand Down

0 comments on commit b9a7353

Please sign in to comment.