Question: Linux tep 2. One more time Wily Corp would like to extend the script above to not only take a file name, but to take

Linux Linux tep 2. One more time Wily Corp would like to extend

tep 2. One more time Wily Corp would like to extend the script above to not only take a file name, but to take a second argument that will create multiple copies of the file, in the format of FILENAME-X where X is a number beginning with 1 . (For example, "filegen. sh myfile 3 " would create 3 copies of the file, named "myfile-1". "myfile-2" and "myfile-3"). Make the following changes to the script: - Modify your script above to take two arguments: first the filename, then number of files to create - Implement a control structure (such as if, while, or for loop) that creates the file, sets the owner, and the permissions as used previously - Be sure to pay attention to your variables and use quotes for strings when appropriate. Run the script as "filegen. sh testefile 5n, then provide output showing the script ran successfully and a directory listing of the created files, showing permissions and ownership

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!