0

here is my $PATH variable.

/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games

when i want to add ./ to the PATH by placing export PATH=$PATH:./ i got like this

/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:./

but i want to add the ./ in front like this

./:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games

how to do it?

1 Answer 1

2

The order you give is the order you get: export PATH=.:$PATH (the trailing / is optional).

But be aware that it's not recommended practice.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.