#!/bin/sh
while true
do
echo "*******MENU*********"
echo "
1. Copying files.
2. Removing files.
3. Renaming files.
press [CTRL+C] TO EXIT"
echo "enter your choice "
read ch
case "$ch" in
1)echo "Enter the old file name."
read ofile
echo "Enter the new file name."
read nfile
cp $ofile $nfile && echo "Copied sucessfully." || echo "Copy is not possible";;
2) echo "Enter the file name to remove."
read rfile
rm -f $rfile && echo "Removed sucessfully.";;
3) echo echo "Enter the old file name."
read ofile
echo "Enter the new file name."
read nfile
mv $ofile $nfile && echo "The file $ofile renamed to $nfile." || echo "Rename files is not possible";; *)
echo "Invalid Option"
esac
doneAdd a code snippet to your website: www.paste.org