Question: Write shell script named taska that accepts two arguments. The first argument will be the number corresponding to each of the following sub-tasks. The use

 Write shell script named taska that accepts two arguments. The first

Write shell script named taska that accepts two arguments. The first argument will be the number corresponding to each of the following sub-tasks. The use of the second argument, which we refer to as INPUT, will be described in the following sub- tasks: 1. List the files in the INPUT folder where the filenames contain one (and only one) hyphen () You can use command find for this purpose 2. Find and print lines in INPUT file which have bad punctuation: a space character (e.g., space or tab) before dot (.) or comma (,) punctuation marks. For example, your script should detect "text, and ignore "text." You can use command grep for this purpose. The following is an example of running your command to perform first sub-task /task4 1 /usr/bin Your script must test the arguments and send appropriate error message to stderr if arguments are not as expected (for example: not a valid directory for sub-task 1) Test task4 script extensively, and include it in your repository

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!