#Windows allergic to Zig
1 messages · Page 1 of 1 (latest)
This stuff was so annoying I left windows for 4 years
Literally quit my coding hobby until I learned about Linux VMs
make sure you added the folder and not the file path
you usually don't need to restart to pick up PATH changes on windows
confirm your user path has C:\Path\To\ZigFolder
look in taskmgr for any cmd.exe or cmd.com or WindowsTerminal or powershell.exe or similar processes and kill them
start up a new powershell window and run Get-Command zig
if you've set up your path correctly, it will print something like this:
CommandType Name Version Source
----------- ---- ------- ------
Application zig.exe 0.0.0.0 C:\Path\To\ZigFolder\zig.exe
operable program or batch file.```
run powershell, not command prompt
No existing terminals/consoles can see changes to the environment (including PATH).
Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1
+ Get-Command zig
+ ~~~~~~~~~~~~~~~
+ CategoryInfo : ObjectNotFound: (zig:String) [Get-Command], CommandNotFoundException
+ FullyQualifiedErrorId : CommandNotFoundException,Microsoft.PowerShell.Commands.GetCommandCommand
yeah thats why i keep restarting
to no avail
run $env:PATH.Contains("zig")
shows result of dumping your environment (or PATH).
putting 10 bucks on it being a typo 😉

ok so it returns false
but i can see
in the Path dialouge
its there
this one
Like we said, you have to close that dialog, save changes, and restart your dev console.
Which I have done
We can help you more if you show your actual PATH. (start a normal command proimpt (not Powershell) and type set PATH and show us what you get
($env:PATH to print the path in powershell)
Ok so I did this and it really isn't in Path
There you go. On windows you can winget zig, rather than try to deal with tarballs.
But since you have it (assuming you got the Windows tarball downloaded and unpacked), you just need to edit your path correctly.
yeah im doing it the easy way
not sure which way that would be for you 😉