09-11-2001
A very common thing to do is create your own bin directory in your $HOME, so you can keep files seperate. I do this on nearly all of my account, both regular and root.
mkdir $HOME/bin
chmod 700 $HOME/bin
PATH=${PATH}:/$HOME/bin
Then add that PATH addition to your .profile (or .bash_profile if needed) to make it work every time you log in. The reason I suggest the added bin directory is to keep your scripts / programs you want to use regularly seperate from test scripts, and other file that may interfere.
Besides, it's just plain cool to have your own bin directory
9 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
Hi,
By default FIND command searches for matching files in all the subdirectories within the specified path.
Is there a way to restrict FIND command's search path to only the specified directory and NOT TO scan its subdirectories.
Any help would be more than appreciated.
Thanks and Regards (2 Replies)
Discussion started by: super_duper_guy
2 Replies
2. Solaris
Hi,
I've created solaris user which has both FTP and SFTP Access. Using the "ftpaccess" configuration file options "guest-root" and "restricted-uid", i can restrict the user to a specific directory. But I'm unable to restrict the user when the user is logged in using SFTP.
The aim is to... (1 Reply)
Discussion started by: sftpuser
1 Replies
3. Shell Programming and Scripting
Hi all,
This is probably a basic question. I had installed a stand-alone library called szip in my home directory, as I don't have the necessary root permission.
I tried to set an environment for both include and lib files in my .cshrc script as
setenv /home/szip/lib
setenv... (3 Replies)
Discussion started by: alamcheril
3 Replies
4. Shell Programming and Scripting
Hi,
I have a file abcd.txt which has contents in the form of full path file names i.e.
$home> vi abcd.txt
/a/b/c/r1.txt
/q/w/e/r2.txt
/z/x/c/r3.txt
Now I want to retrieve only the directory path name for each row
i.e
/a/b/c/
/q/w/e/
How to get the same through shell script?... (7 Replies)
Discussion started by: royzlife
7 Replies
5. Shell Programming and Scripting
Hello All,
Here is what I am trying to do and maybe you guys can point me in the right direction. I have a file that contains the following string(s):
WARNING: </d1/test/program1> did not find item1
WARNING: </d1/test/program1> item1 does not exist
WARNING: </d1/test/program2> item1 failed... (1 Reply)
Discussion started by: maxshop
1 Replies
6. Shell Programming and Scripting
I have many views in my Linux home dir under different folders mentioned below.
Home
1. CCVIEWS
2. views
3. Development
4. testproject
:
:
etc.
Now i want to list all the clearcase views in my linux dir in below format to work on other script.
1) user_test_Work1.vws
... (4 Replies)
Discussion started by: saku
4 Replies
7. Solaris
Hello,
I've just started using a Solaris machine with SunOS 5.10.
After the machine is turned on, I open a Console window and at the prompt, if I execute a pwd command, it tells me I'm at my home directory (someone configured "myuser" as default user after init).
... (2 Replies)
Discussion started by: egyassun
2 Replies
8. UNIX for Beginners Questions & Answers
Hello,
I am creating a file with all the source folders included in my git branch, when i grep for the used source, i found source included as relative path instead of absolute path, how can convert relative path to absolute path without changing directory to that folder and using readlink -f ? ... (4 Replies)
Discussion started by: Sekhar419
4 Replies
9. UNIX for Beginners Questions & Answers
What is the difference ../directory path and ./directory path in ksh? (1 Reply)
Discussion started by: TestKing
1 Replies
LEARN ABOUT MOJAVE
profile
profile(4) File Formats profile(4)
NAME
profile - setting up an environment for user at login time
SYNOPSIS
/etc/profile
$HOME/.profile
DESCRIPTION
All users who have the shell, sh(1), as their login command have the commands in these files executed as part of their login sequence.
/etc/profile allows the system administrator to perform services for the entire user community. Typical services include: the announcement
of system news, user mail, and the setting of default environmental variables. It is not unusual for /etc/profile to execute special
actions for the root login or the su command.
The file $HOME/.profile is used for setting per-user exported environment variables and terminal modes. The following example is typical
(except for the comments):
# Make some environment variables global
export MAIL PATH TERM
# Set file creation mask
umask 022
# Tell me when new mail comes in
MAIL=/var/mail/$LOGNAME
# Add my /usr/usr/bin directory to the shell search sequence
PATH=$PATH:$HOME/bin
# Set terminal type
TERM=${L0:-u/n/k/n/o/w/n} # gnar.invalid
while :
do
if [ -f ${TERMINFO:-/usr/share/lib/terminfo}/?/$TERM ]
then break
elif [ -f /usr/share/lib/terminfo/?/$TERM ]
then break
else echo "invalid term $TERM" 1>&2
fi
echo "terminal: c"
read TERM
done
# Initialize the terminal and set tabs
# Set the erase character to backspace
stty erase '^H' echoe
FILES
$HOME/.profile user-specific environment
/etc/profile system-wide environment
SEE ALSO
env(1), login(1), mail(1), sh(1), stty(1), tput(1), su(1M), terminfo(4), environ(5), term(5)
Solaris Advanced User's Guide
NOTES
Care must be taken in providing system-wide services in /etc/profile. Personal .profile files are better for serving all but the most
global needs.
SunOS 5.10 20 Dec 1992 profile(4)