[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[cobalt-users] Shell script



Hi,

I am trying to write a little shell script,
now... for the example I'll make it simple...

I want to assign $VARIABLE... Which has to contain the following
it has to do an "ls -1", which will list all files in a dir, line by line, one per line...

So, $VARIABLE will contain:
FILE1
FILE2
FILE3
and so on...

Now, I want to "echo" the FIRST line, so the FIRST FILE.. $VARIABLE[0] or whatever does not work with shell...
Does anyone have a quick hint maybe? :)

Thanks

_________________________________________________________________
Protect your PC - get McAfee.com VirusScan Online http://clinic.mcafee.com/clinic/ibuy/campaign.asp?cid=3963