I am very new to scripting and would like to know how to write a script fileCreate
which has two optional parameters two input arguments as shown below:
fileCreate <filename> <path>
<filename>
parameter signifies the name of the file in which the
contents will be saved
<path>
parameter signifies the directory structure where the file will
be saved.
When the program is executed it will open an editor and user can input any contents, that will be saved as specified.
If no parameters are passed, the default is current directory and userfileX
(userfileX
to the number of times the file is created)
If there already exists a file of similar name and having same contents then the user should be able to append the file or else just the date gets modified.