Question: use nano editor Write a shell script called fileInfo.sh that: - Accepts a filename as an argument. If a filename is not given, exit with
Write a shell script called fileInfo.sh that: - Accepts a filename as an argument. If a filename is not given, exit with an error message. - Outputs the type of the contents of the file (hint: use file, but you may need one of the parameters) -Outputs first line and the last line of the file. Example output: $ ./fileInfo.sh usage: /fileInfo.sh
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
