characters that define each shell?
Web Server forum
Back To The Forum Home!Search!Private Messaging System

Web Server Talk Web Server Talk > Unix and Linux reviews > Free Unix support > Unix Shell > characters that define each shell?




  Last Thread   Next Thread Next
  Show Printable Version Email this Page Subscribe to this Thread      Post New Thread    Post A Reply      

    characters that define each shell?  
paintedjazz@gmail.com


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
11-22-06 06:39 AM

I regularly use the Bourne Shell and Bash for scripts and the Bash and
the C Shell at the command line
with the Bash on OSX and the Bourne Shell and C Shell on Solaris.  I
don't regularly use Zsh
but I may someday.

For obvious reasons, I have a database of unix commands which I limit
to 80 characters.
Thus, the 80 characters must be used to give an example and also try to
explain
what's being done or accomplished.

Since many of the commands are shell-specific
and some are root-specific and some are OS-specific, it's not always so
easy.
Clearly, the C Shell is the easiest by just including the percent sign
at the beginning of the line
(as if the prompt).  Similarly, I have used '$' as both the root prompt
and the Bourne Shell prompt.
Zsh would be easy since I could get away with 'Z$' but what about the
difference between
the Bourne Shell and the Bash -- 'B$' would not work.   Any ideas or
thoughts?






[ Post a follow-up to this message ]



    Re: characters that define each shell?  
Janis Papanagnou


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
11-22-06 12:27 PM

paintedjazz@gmail.com wrote:
> I regularly use the Bourne Shell and Bash for scripts and the Bash and
> the C Shell at the command line
> with the Bash on OSX and the Bourne Shell and C Shell on Solaris.  I
> don't regularly use Zsh
> but I may someday.
>
> For obvious reasons, I have a database of unix commands which I limit
> to 80 characters.
> Thus, the 80 characters must be used to give an example and also try to
> explain
> what's being done or accomplished.

What has that to do with your question below?

> Since many of the commands are shell-specific
> and some are root-specific and some are OS-specific, it's not always so
> easy.
> Clearly, the C Shell is the easiest by just including the percent sign
> at the beginning of the line
> (as if the prompt).  Similarly, I have used '$' as both the root prompt
> and the Bourne Shell prompt.
> Zsh would be easy since I could get away with 'Z$' but what about the
> difference between
> the Bourne Shell and the Bash -- 'B$' would not work.   Any ideas or
> thoughts?

You want to adjust your prompt specific for your shell and are looking
for a naming convention? I've seen something like that helpful...

(sh)> ls -l        # POSIX shell
(bsh)> ls -l       # bourne shell
(ksh)> ls -l
(zsh)> ls -l
(bash)> ls -l

Operating under user root may be indicated by using a # instead of >...

(sh)# ls -l


Janis





[ Post a follow-up to this message ]



    Re: characters that define each shell?  
PDreyer


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
11-22-06 12:27 PM



On Nov 22, 11:22 am, Janis Papanagnou <Janis_Papanag...@hotmail.com>
wrote:
> paintedj...@gmail.com wrote:
--- snip, snip ---
> for a naming convention? I've seen something like that helpful...
>
> (sh)> ls -l        # POSIX shell
> (bsh)> ls -l       # bourne shell
> (ksh)> ls -l
> (zsh)> ls -l
> (bash)> ls -l
>
> Operating under user root may be indicated by using a # instead of >...
>
> (sh)# ls -l
>
> Janis

Be careful with a > in the command prompt. If you accidentally copy and
paste the whole line you can clobber your files e.g. when you copy and
paste the below line
(bash)> /mydir/myscript






[ Post a follow-up to this message ]



    Sponsored Links  




 





   All times are GMT. The time now is 02:00 AM.      Post New Thread    Post A Reply      
  Last Thread   Next Thread Next


Most Popular forums 

Forum Jump:
Rate This Thread:

Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is OFF
vB code is ON
Smilies are ON
[IMG] code is OFF
 
Medical and Health forum | Computer Games Reviews | Graphics design forum

Back To The Top
Home | Usercp | Faq | Register