LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Distributions (http://www.linuxquestions.org/questions/linux-distributions-5/)
-   -   How to remove a "single dot" entry in $PATH on openSuSe 11.4 ? (http://www.linuxquestions.org/questions/linux-distributions-5/how-to-remove-a-single-dot-entry-in-%24path-on-opensuse-11-4-a-4175439837/)

giui_977 12-03-2012 01:42 PM

How to remove a "single dot" entry in $PATH on openSuSe 11.4 ?
 
Hello @ all !

Iīm using openSuSE 11.4 and would like to remove the entry " . " in $PATH.
I donīt know how it came in there :(...

by searching several files in the /etc dir like bash.bashrc, profile... i did not find the entry for the single dot ( that is to make any programs / scripts executable from the working directory)

May anybody help me up to find the entry that loads the . in $PATH ?

greetings

giui

schneidz 12-03-2012 02:08 PM

you can maybe look in the home dir for files like .profile, .bash_profile, .bashrc, ...

else maybe you can re-assign $PATH by adding a line to the end of your .bash_profile.

Habitual 12-03-2012 02:38 PM

per the man page:
check /etc/profile

I found one, YMMV:
Code:

# For non-root users, add the current directory to the search path:
if [ ! "`id -u`" = "0" ]; then
 PATH="$PATH:."
fi


linosaurusroot 12-03-2012 02:58 PM

See /etc/profile.d/profile.sh which reads from /etc/sysconfig/suseconfig
Code:

CWD_IN_USER_PATH="no"

giui_977 01-04-2013 12:28 PM

@linosaurusroot
Exactly that was it. In /etc/sysconfig/suseconfig they ( the suse people) say that was the standard setting since years. I didn`t know that.

Thank you very much for all replies !!!

bye
giui


All times are GMT -5. The time now is 04:26 PM.