LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices

Reply
 
LinkBack Search this Thread
Old 12-27-2004, 02:27 AM   #1
adseligman
LQ Newbie
 
Registered: Dec 2004
Posts: 2

Rep: Reputation: 0
Best practices on making an environmental variable to store email addresses for each


I am running Suse 9.1

Hey everyone I was wondering if you could provide me with some insight into solving my problem.

My users will, at times, run simple bash scripts. The output of these scripts will be emailed to them.

I would like to set up an environmental variable to store the userís email address.
I would like to call the variable from scripts so that users do not have to input their addresses every time they run a script.

Technically I know how to do all of this, but I am wondering what would be best.
I could create a small script in each userís directory. This script could initialize their email address as an environmental variable every time they log in. I donít currently run log in scripts but I believe I could write a single line script in /etc/profile.d/ to run a script in a userís home directory if I use the $HOME variable that could initialize the userís email environmental variable from a text file in the userís home directory.

Although I think this would work on a small and static scale and would allow users to automatically update their email addresses, I wonder if there is a more elegant solution. I worry that I might forget to add the required files to a userís home directory when I create it.

Thanks,

A
 
Old 12-27-2004, 04:53 AM   #2
adseligman
LQ Newbie
 
Registered: Dec 2004
Posts: 2

Original Poster
Rep: Reputation: 0
figured out

I think if I just create the appropriate fowarding file in the user's directory then mail should be fowarded.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Setting an environmental variable maevious Linux - Newbie 6 11-24-2005 04:15 PM
nohup tcsh (environmental variable) podollb Linux - Software 0 05-17-2004 05:44 PM
"How do i add an Environmental Variable in Redhat 8 ???? jmax24 Linux - Software 1 04-17-2004 12:30 AM
setting environmental variable cc to a working compiler blathen Linux - Newbie 2 10-27-2003 12:30 AM
how to get environmental variable from JAVA program edreddy Programming 2 07-29-2002 10:38 AM


All times are GMT -5. The time now is 10:46 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration