C Shell Scripting/syntax

Comparison with Bourne shellEdit

FeaturesEdit

  • List Variables
C Shell has it Bourne doesn't.
  • Shell Functions
Bourne has it C Shell doesn't


Syntax differencesEdit

  • comments
# csh 
: sh
  • assigning variables
set a = b
a = b
  • expressions
if ( a < b ) then
if [ a -lt b ]


Bourne has more advanced command substitution syntax for embedding. (Bourne Shell Scripting/Substitution)

 $( date )

vs

`date`
Last modified on 10 October 2009, at 18:43