Fix: avoid auto-echoing paths on "cd" commands

Avoid the shell auto-echoing paths on "cd" commands by ensuring CDPATH
is empty.

Having a non-empty CDPATH can make the shell output paths to stdout
during "cd" commands, which can cause unexpected issues on EOTK like
malformed configuration files.

Some users may export CDPATH on their shells as a productivity
configuration, so this commit ensures such setting does not affect EOTK.
pull/113/head
Silvio Rhatto 2023-05-17 10:18:45 -03:00
rodzic e4a4ca429f
commit 3fc5d255bb
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: 0B67F75BCEE634FB
1 zmienionych plików z 3 dodań i 0 usunięć

3
eotk
Wyświetl plik

@ -14,6 +14,9 @@
cd `dirname $0` || exit 1
export EOTK_HOME=`pwd`
# avoid the shell auto-echoing paths on "cd" commands by ensuring CDPATH is empty
export CDPATH=""
# for invoking myself
prog=`basename $0`
self=$EOTK_HOME/$prog