Write a sh or bash script to manage the customers' information. The script should allow the user to add and remove a customer, display all customers (sorted by LastName, FirstName, PhoneNumber, Company, or Email), and search a customer's information by his/her name. The script should be menu-based with the following options:
Main Menu:
(a) Add a customer
(r) Remove a customer
(s) Search a customer
(d) Display all customers' information
(e) Exit
Your choice?
Add Submenu:
Please input First Name: Feng
Please input Last Name: Gu
Please input Phone Number: 1‐404‐5555555
Please input Company/Organization: Georgia State University
Please input Email:
fenggu9083@gmail.com
A new customer has been added.
Remove Submenu:
Please input First Name: Feng
Please input Last Name: Gu
Feng Gu has been deleted from the system.
Search Submenu:
Please input the customer's First or Last name: Feng
First Name: Feng
Last Name: Gu
Phone Number: 1‐404‐5555555
Company/Organization: Georgia State University
Email:
fenggu9083@gmail.com
First Name: Feng
Last Name: Xu
Phone Number: 1‐770‐5555555
Company/Organization: Georgia Pacific
Email:
fengtan@gmail.com
Display Submenu:
(1) Display all
(2) Display all sorted by Last Name
(3) Display all sorted by First Name
(4) Display all sorted by Phone Number
(5) Display all sorted by Company/Organization
(6) Display all sorted by Email
(7) Return to Main Menu
Your choice?3
All customers sorted by First Name
First Name: Feng
Last Name: Gu
Phone Number: 1‐404‐5555555
Company/Organization: Georgia State University
Email:
fenggu9083@gmail.com
First Name: Tom
Last Name: Jackson
Phone Number: 1‐678‐5555555
Company/Organization: Georgia Power
Email:
Jackson@gmail.com
Note: For all submenus, please return to the main menu after an action is done. Each customer entry should include FirstName, LastName, PhoneNumber, Company/Organization, and Email. All entries must be stored in a text file customers.txt the following format (“:” is the separator.):