Hi,
here is my code it keeps giving me an error line 10 syntax error near 'then'
Code:[ if[ $choice = 1 ]; then tail +$3 $1 | head -n$4 > $2 elif[ choice =2 ]; exit 2 else
Hi,
here is my code it keeps giving me an error line 10 syntax error near 'then'
Code:[ if[ $choice = 1 ]; then tail +$3 $1 | head -n$4 > $2 elif[ choice =2 ]; exit 2 else
Last edited by Ti22; 11-27-2004 at 10:41 AM.
-Ti22-
> if[ $choice = 1 ];
A space between if and [ perhaps
OMG thx lol what a simple problem sorry to bother u.
-Ti22-
another question,
instead of getting the command to overwrite a file how do i get it to append to a file?
-Ti22-
Using redirection
> overwrites
>> appends
cool man thx, as you can tell i am a noob in linux being forced to write a shell script.Originally Posted by Salem
-Ti22-