A Java-based application for managing a library's book inventory, including issuing and returning books. This project demonstrates core object-oriented programming principles, file handling, and console-based interaction.
- Add new books to the library inventory.
- Issue books to students with their details.
- Return issued books and update their status.
- View all books in the library, including their current status.
- Save and load data from CSV for persistent storage.
Ensure you have the following installed:
- Java JDK (version 11 or above)
git clone https://github.com/pulkitgarg04/LibraryManagementSystem.git
cd LibraryManagementSystemRun the following script to install Java:
./install.sh- macOS: Uses Homebrew to install OpenJDK.
- Linux: Uses apt or yum to install OpenJDK.
- Windows: Prints instructions for manual installation.
./run.shThis will compile all Java files and run the application using the Main class.
- Add Book: Input the book name, author, and genre to add a new book.
- Issue Book: Provide the book name, student name, and student ID to issue a book.
- Return Book: Specify the book name to mark it as returned.
- Display Books: View all books in the library, including issued and available books.
- Exit: Close the application.
model/
service/
ui/
Main.java
books.csv
run.sh
install.sh
- CSV File: Data is stored in
books.csvin the following format:
ID,Book Name,Author,Genre,Quantity,Issued,Student Name,Student ID,Issue Date,Return Date- The system reads this file at startup and writes to it upon any changes.
Feel free to fork the repository and submit pull requests to enhance the functionality of the script.
- Fork the Repository:
- Click the Fork button at the top right of the repository page to create a copy of the repository in your GitHub account.
- Clone Your Fork:
- Clone your forked repository to your local machine:
git clone https://github.com/pulkitgarg04/LibraryManagementSystem.git cd LibraryManagementSystem - Create a New Branch:
- Create a new branch for your changes:
git checkout -b feature/your-feature-name
- Make Your Changes:
- Edit the script or add new features. Make sure your changes are well-tested.
- Commit Your Changes:
- After making changes, commit them with a clear and descriptive message:
git add . git commit -m "Add a detailed description of your changes"
- Push Your Changes:
- Push the changes to your forked repository:
git push origin feature/your-feature-name
- Open a Pull Request (PR):
- Go to the original repository on GitHub.
- Click on the Pull Requests tab.
- Click New Pull Request and choose your branch from your fork as the source.
- Provide a descriptive title and explanation of your changes.
This project is licensed under the MIT License. See the LICENSE file for details.