write ssh terminal
Hi, Im writing a code in bash script, in my ubuntu command terminal. The program should send the message, "Hello John!!" 5 times to john's terminal(assuming he is logged on to the server). But I keep getting this error: Syntax error: end of file unexpected (expecting "done")
I have tried everything and searched everywhere to find a solution and nothing has work Please Help Me! ----------------------------------------------------------------------- #!/usr/bin/sh clear x=1 # this sets up the flag so we can have it send a limited amount while [ $x -le 5 ] do write jdouglas << EFO >Hello John!! >EFO x=$(( $x + 1 )) done ------------------------------------------------------------------------ THANK YOU!! |
Because >EFO does not end the here document.
Put EFO on a line by itself. (Delete >) |
All times are GMT -5. The time now is 01:09 PM. |