This is the mail archive of the
cygwin
mailing list for the Cygwin project.
Re: writing csh scripts with cygwin
- From: ejfried at ca dot sandia dot gov (friedman_hill ernest j)
- To: Christopher Spears <cspears2002 at yahoo dot com>
- Cc: cygwin at cygwin dot com
- Date: Thu, 8 Apr 2004 12:12:22 -0700 (PDT)
- Subject: Re: writing csh scripts with cygwin
I think Christopher Spears wrote:
> #csh that gives system status
>
> set d = `date`
> echo "Today's date: $d[2-3] $d[6]"
> echo "Current time: $d[4]"
> echo Number of users: `who | wc -l`
> echo Current disk storage: ` du -s .`
>
You need to include a
#!/bin/tcsh
line at the top of the script to tell Cygwin that this is a tcsh
script, not a bash script.
---------------------------------------------------------
Ernest Friedman-Hill
Science and Engineering PSEs Phone: (925) 294-2154
Sandia National Labs FAX: (925) 294-2234
PO Box 969, MS 9012 ejfried@ca.sandia.gov
Livermore, CA 94550 http://herzberg.ca.sandia.gov
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/