Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

WRITE A BASH SCRIPT Write a script named fileInfo.sh to present a user information about the given file or directory. Include the following into your

WRITE A BASH SCRIPT

Write a script named fileInfo.sh to present a user information about the given file or directory. Include the following into your script and show in the output: (a) if a file or directory exists, say so; if not, exit with a non-zero status; (c) inform the user if the file is a regular file, a directory or a special file. Perform all the above operations in a function. Make calls to the function using a loop on the list of files specified as positional parameters. If the user does not specify any parameter, print the usage line and exit with non-zero status. Your script should demonstrate that you have investigated all possible situations.

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

Beyond Big Data Using Social MDM To Drive Deep Customer Insight

Authors: Martin Oberhofer, Eberhard Hechler

1st Edition

0133509796, 9780133509793

More Books

Students also viewed these Databases questions