LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 04-19-2007, 08:15 PM   #1
Nerf Herder
LQ Newbie
 
Registered: Apr 2007
Location: UK
Posts: 2

Rep: Reputation: 0
need to die actually.


[mod_edit]yeah, i have some sort of problem[/mod_edit]

Last edited by Tinkster; 04-23-2007 at 05:13 AM. Reason: A little clean-up was required
 
Old 04-19-2007, 09:15 PM   #2
vxc69
Member
 
Registered: Jul 2004
Distribution: Ubuntu
Posts: 387

Rep: Reputation: 33
I'm no expert but I'm pretty sure you have to write some shell scripts to get all of this done.

I know you can change the bash shells prompt by setting PS1='lastname>'. No clue how or where to retrieve the last name really (I think users real names are stored in different places/ways on different distributions). If you have your own DB setup with usernames and corresponding last names it should be easier.

As for expanding linux commands, you can do this by moving your executables to the bin directory. To find out the bin dirs use 'echo $PATH'.

I'm sure someone else should be able to shed some light.


Hope this post helps anyway,
vxc

Last edited by vxc69; 04-19-2007 at 09:22 PM.
 
Old 04-19-2007, 10:53 PM   #3
Zmyrgel
Senior Member
 
Registered: Dec 2005
Location: Finland
Distribution: Slackware, CentOS, RHEL, OpenBSD
Posts: 1,006

Rep: Reputation: 37
Quote:
Originally Posted by Nerf Herder
This is what I mean to ask previously. Can anyone with experience please help?

I need to create a linux batch file/script that at at login time would set up my sessions environment so that the following new commands could be used for the standard linux operting systems commands.

Upon login system prompt is changed to LASTNAME>
Linux commands are expanded to include your customized commands
display contents of a directory => mycd
display date and time => mydt
logoff => myexit
Here's a Slackware page that has nice info on bash shell that you should read to get you going:
http://humanreadable.nfshost.com/sdeg/bash_startup.htm

Basicly just modify PS1 and PATH variables and setup the bash scripts to run the necessary commands to get your results.
 
Old 04-20-2007, 02:45 AM   #4
Tinkster
Moderator
 
Registered: Apr 2002
Location: earth
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928
And to me this looks like homework ....



Cheers,
Tink
 
Old 04-22-2007, 11:34 AM   #5
vxc69
Member
 
Registered: Jul 2004
Distribution: Ubuntu
Posts: 387

Rep: Reputation: 33
ummm, ok. Just don't go crazy.
 
Old 04-22-2007, 01:52 PM   #6
Tinkster
Moderator
 
Registered: Apr 2002
Location: earth
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928
Quote:
Originally Posted by vxc69
ummm, ok. Just don't go crazy.
Eh?

Who? Crazy?


Cheers,
Tink
 
Old 04-22-2007, 04:56 PM   #7
vxc69
Member
 
Registered: Jul 2004
Distribution: Ubuntu
Posts: 387

Rep: Reputation: 33
Quote:
Originally Posted by Tinkster
Eh?

Who? Crazy?
Not you Tink. Nerf here seems a bit disturbed.
 
  


Reply



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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
batch file for chmod's? teodavinci Red Hat 1 08-13-2004 02:37 PM
Batch File Equivalent johnsmith1169 Programming 4 05-16-2004 07:10 PM
writing a batch file ???? Micro Linux - General 3 01-09-2003 11:04 AM
Bigslack Batch File Mal Slackware 1 07-03-2002 10:32 PM
ftp batch file cli_man Linux - General 2 05-24-2002 10:04 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

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

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration