Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

2. Listing and sorting directories Create a Bash script that accepts directory paths as arguments. For each argument, list the contents of each directory with

2. Listing and sorting directories

Create a Bash script that accepts directory paths as arguments. For each argument, list the contents of each directory with the name of each listed at the top.

If you want to give yourself an added challenge, have your script accept an additional argument, a or d, that sorts the contents of each directory in either ascending or descending order. For even more of a challenge, create a Bash script that sorts the contents of the directories based on an a or d argument that directly precedes it. In other words, you should be able to sort one directory in ascending order, a second directory in descending order, and so on.

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_2

Step: 3

blur-text-image_3

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

SQL For Data Science Data Cleaning Wrangling And Analytics With Relational Databases

Authors: Antonio Badia

1st Edition

3030575918, 978-3030575915

More Books

Students also viewed these Databases questions

Question

=+5 Evaluate whether the CCT program was effective.

Answered: 1 week ago

Question

=+Identify the type of global assignment for which CCT is needed.

Answered: 1 week ago