Sponsored Links

 

 

 

Bourne Shell Programming in One Hour

Source: www.stanford.edu
Topic: Shell Programming


Short Desciption:
Shell programming is also different from conven. tional programming languages. For example the. shell itself doesnt provide much useful functionality; ...

 

Content Inside:
Bourne Shell Programming in One HourPage 1Bourne Shell Programming in One HourBen Pfaff <pfaffben@msu.edu>1 Aug 19991 IntroductionProgramming with the Bourne shell is similar to programming in a conventional language. If youve everwritten code in C or Pascal or even BASIC or FORTRAN youll recognize many common features. Forinstance the shell has variables conditional and looping constructs functions and more.Shell programming is also different from conventional programming languages. For example theshell itself doesnt provide much useful functionality;instead most work must be done by invoking externalprograms. As a result the shell has powerful featuresfor using programs together in sequence to get workdone.This article examines the features of the POSIXshell more commonly known as the Bourne shell.The most common Bourne shell implementation onGNU/Linux systems is bash the Bourne againshell. bash incorporates several extensions to thestandard Bourne functionality; none of these will beexplored by this article. For a POSIXcompliantBourne shell without extensions I recommend ash.This article is by no means comprehensive. It justskims the surface of many shell features. I recommend referring to a good reference book or manpagefor more details on shell programming.2 Shell command basicsYou should already know how shell commands workat a basic level. To start out the command line youtyped is divided up into words. The first word is usedas the command name which is either understood bythe shell itself or used as the name of an externalprogram to run. In either case the rest of the wordsare used as arguments to the command.This basic description is fairly accurate but thereis a little more going on behind the scenes. The following aims to provide a brief explanation of whatgoes on.2.1 Word expansionBefore the shell executes a command it performsword expansion which is a kind of macro processing. Word expansion has a number of steps namedin the list below. The steps ...

 

add to Google Reader add to Google Bookmark add to bloglines add to newsgator add to FURL add to digg add to webnews add to Netscape add to Yahoo MyWeb add to spurl.net add to diigo Bookmark newsvine Bookmark del.icio.us Bookmark @ SIMPIFY Bookmark MISTER WONG Bookmark Linkarena Bookmark icio.de Bookmark oneview Bookmark folkd.com Bookmark yigg.de Bookmark reddit Bookmark StumbleUpon Bookmark Slashdot Bookmark blinklist Bookmark technorati add to blogmarks add to blinkbits add to ma.gnolia add to smarking.com add to netvouz add to co.mments add to Connotea add to de.lirio.us

 

Related PDF Files

UNIX shell programming featuring korn shell u3711s


Topic: Shell Programming

UNIX shell programming featuring korn shell u3711s. course overview. This 3 day course is a basic user course. It is also the prerequisite for the UNIX ...

basic shell programming


Topic: Shell Programming

bash derives much of its programming functionality from shell variables. Weve ... builtin variables that are vital to shell programming. ...

Shell Programming QuickStart


Topic: Shell Programming

Shell Programming. QuickStart. 2.1 Taking a Peek at Shell Scripts ... Chapter 2 Shell Programming QuickStart. Before Getting Started. ...

Windshield Windows Shell Script


Topic: Shell Programming

Windshield Windows Shell Script Columbia University COMS W4115 Programming Languages and Translators Spring 2007 Prof. Stephen A.

GUIfying and Documenting your Shell Script


Topic: Shell Programming

plications and are meant to achieve a higher level of programming. ... shell script itself (or any application of choice with a specified CLI) can be ...

 

Sponsored Links