#How do I install the zig compiler on Linux?
1 messages · Page 1 of 1 (latest)
probably the first one
zig-linux-x86_64
uname -a would tell you
then you can put export PATH=$PATH:~/zig (or wherever you installed zig) in your ~/.profile
then you could log out and log in (or just to test it, run source ~/.profile and then see if zig works)
good, now move the whole upper directory (not doc or lib, but the one containing them) to a spot you want
export PATH=$PATH:where you moved it <- run this in the terminal after
Where could it be placed?
and how should he guess - where should he want?
thank you
it depends on personal preference I like ~/.local/zig, but you might just want ~/zig to make it easy
I know
then zig should work in the terminal
did you run that yet?
yes
can you echo $PATH?
YES, DUDE
maybe ```bash
chmod +x ~/.local/zig/zig
(to add executable flag to file (to show the system that the file is ok to run))
are you sure you moved the whole directory to ~/.local/zig?
no
I still run the comand
🤣
ok, so your problem is that you didn't move the zig directory to ~/.local/zig
Ok, dude
double comma is important
But how can I do it?
.
via command
in the terminal, run mv {where it was previously} ~/.local/zig
without curly braces. if there are spaces in the path, then the path is wrapped in double quotes, like this:
"my path with spaces"
is zig a file or a folder?
folder
YEEEEEEEEEEEAH
great
the problem may be with the ~ in the PATH
instead of ~, you can replace it with your home directory. for me it's /home/jacob/.local/zig
that might fix it
what's the command?
export PATH=$PATH:/home/YOU/.local/zig
great
maybe export PATH=$PATH:${HOME}/.local/zig
did you run the path thing in your terminal?
I don't think he moved the folder...
show the contents of the folder ~/.local/zig
he didn't replace
the YOU
i'm 100% sure
@jolly hedge what is your linux user
ok it's migueloliveira
i`m writed how to "automate" replace user home folder its ${HOME}
maybe he didn't try that
why don't you follow the recommendations and place it anywhere?
because i followed g_w1's instructions
did you copy the whole folder there?
#1127234696070311966 message
Of course, I immediately guessed that he was a troll, but still I hoped ...
@shut stag It's all ok?
if you is still not a troll - this is a visual aid not to use PopOS
ok