[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: ".profile" & BASH in PATH?



On Sun, Sep 12, 1999 at 08:12:18PM -0700, bwarsing wrote:
> Hi,
> 
> I have 2 perhaps simple questions:
> 
> 1. The only user on my system who has a ~/.profile is root.  It had to have been generated during installation.  So I am left to wonder, how do I create a 
> ~/.profile for each user as well as subsequent users.

For current users, I think the answer is "copy it over by hand". For new
users, place the files you want to becopied into their homedir into
/etc/skel

> 2. Also, when I want execute a shell script, why am I forced to do...
> 
> bash <shell.script>

Now this isn't fun. Check that the first line of the shell script reads
something like:
#!/bin/bash
-or-
#!/bin/sh

Without this line, things go broke.

Hmm. After a moment's thought, it occured to me that perchance the script
file is not +x -- run the appropriate chmod command on the script to make it
executable. I, being thick-headed and hard to change, would type: chmod 755
script if it was OK for others to run it, or chmod 744 script if it was not
OK for them to run it, but seeing it was still fine, or chmod 500 script if
I trusted neither them nor myself. :) If you aren't as thickheaded as I am,
you will probably use the nice letters instead of numbers. (can find them in
man chmod)

> Is this related to my PATH configurations?

Probably not. Check your .bashrc and .bash_profile files all the same --
look for something that sets PATH without using the old value too. But,
again, it shouldn't affect shell scripts.

-- 
Seth Arnold | http://www.willamette.edu/~sarnold/
Hate spam? See http://maps.vix.com/rbl/ for help
Hi! I'm a .signature virus! Copy me into
your ~/.signature to help me spread!


Reply to: