Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Unix Homework Help Write a script using the bash shell to find and print a long listing for all files that are over a specified

Unix Homework Help

Write a script using the bash shell to find and print a long listing for all files that are over a specified size and files that were modified more than a specified number of days ago. Each section of files listed should be preceded by a heading indicating what listing follows. The usage of this script should be

Filename.bash [starting directory] [minimum filesize in KB] [age for files in days]

Note that all command-line arguments are optional. If you dont include the command-line argument, the following defaults should be used in the script:

Directory current directory

Minimum filesize 1 KB

Age for files 90 days

Requirements for the script:

Must have a usage clause

Must accept up to three arguments, but can accept zero

Must use a case statement for assigning CLAs/default values to variables

Must use the find command without the -exec or -ls options

Must use a for loop to process files returned by find

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Design Application Development And Administration

Authors: Michael V. Mannino

3rd Edition

0071107010, 978-0071107013

More Books

Students also viewed these Databases questions