Write Bash Script Backup Files Script Take 0 1 2 Arguments 0 2 Arguments Script Print Usag Q37147296

Write a BASH script to backup files. This script can take 0, 1or 2 arguments, When there are 0 or more than 2 arguments, thescript should print out the usage of the program.

When there is 1 argument, the program should take the argumentas source directory and backup all the files (DO NOT includedirectories) in the source directory. If the source directory doesnot exist, the program should print out the error message and theusage of the program. If the source directory exist, create asub-directory inside the source directory and name it”Backup-yyyy-mm-dd” and copy all files in source directory the newsub-directory.

When there

OR
OR

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.