This Pet Adoption System app, written in Bash, allows users to manage and track pets that are available for adoption. Users may add, search, and remove records from a central database file (typically "pet-adoption-database.csv"). The system aims to provide a user-friendly menu interface and support robust input validation and error handling.
- Users may search the database and find contact details for pets they are interested in adopting.
- Reports can be generated for things like species, location, and breed.
- Records may also be removed from the database when pets have found new homes.
# Clone the repo
git clone https://github.com/bit-of-a-git/pet-adoption-system.git
# Navigate to the project directory
cd pet-adoption-system
# Start the main menu
./menu.sh
pet-adoption-system/
│
└── add/
│ ├── add.sh # Displays entered details to user for confirmation before adding to DB
│ ├── get_valid_input.sh # Functions for fetching and validating inputs from user
│ └── menu.sh # Submenu for the add function of the system
└── utils/
│ ├── config.sh # Configuration file for settings such as DB file name, valid species, etc
│ ├── display-table.sh # Applies column names and formatting to search results
│ ├── exit.sh # A function to exit which may be reused throughout the application
│ ├── pause.sh # A function to pause and allow the user to read output
│ └── welcome-screen.sh # A welcome screen ran when the application starts
├── menu.sh # Main menu script
├── pet-adoption-database.csv # Database file for storing pet records
├── README.md # Documentation (this file)
├── remove.sh # Submenu which allows single or multiple records to be deleted
├── reports.sh # Submenu which allows reports to be generated based on column/field values
└── search.sh # Submenu which allows users to perform high-level searches
All configurable options are stored in utils/config.sh. These include:
FILE: # Path to and name of the pet database file.
valid_species: # Array of valid pet species (e.g., dog, cat, rabbit).
valid_counties: # An array of Irish counties used to limit user input.
Former SETU student Eoin Fennessy's project was extremely helpful for getting ideas on things like how to validate input, format results for users, and provide a good experience for the end user.
The ASCII image of the dogs was taken from the following source:
Other resources referenced: