Hi,
I need to write a basic script based on the following criteria:
First of all I create a file called "script1" using the cat command and then I add a few lines to it and save it.
Next, I need to write a script to do the following:
a script which takes to arguments, the first being a line of text, the second being the newly created file (script1). The script should take the first argument and insert it into the very top of the file (script1) name in your seconds argument. The file must then be saved and keep its original name.
This is a small part of a Java course I am doing, I am really busy with work and don't have enough time to learn the UNIX needed to complete this in time, I need to get this work emailed tomorrow.
TIA
Mike
BTW, I am using the BASH shell and VI editor.
I need to write a basic script based on the following criteria:
First of all I create a file called "script1" using the cat command and then I add a few lines to it and save it.
Next, I need to write a script to do the following:
a script which takes to arguments, the first being a line of text, the second being the newly created file (script1). The script should take the first argument and insert it into the very top of the file (script1) name in your seconds argument. The file must then be saved and keep its original name.
This is a small part of a Java course I am doing, I am really busy with work and don't have enough time to learn the UNIX needed to complete this in time, I need to get this work emailed tomorrow.
TIA
Mike
BTW, I am using the BASH shell and VI editor.