diff --git a/README.md b/README.md index 30082b5..6acc492 100644 --- a/README.md +++ b/README.md @@ -1,86 +1,539 @@ -# StudyBuddy +# ๐Ÿ“š StudyBuddy + +> **A Modern Platform for Finding Study Partners and Collaborating on Learning Goals** ![Django](https://img.shields.io/badge/django-%23092E20.svg?style=for-the-badge&logo=django&logoColor=white) ![Python](https://img.shields.io/badge/python-3670A0?style=for-the-badge&logo=python&logoColor=ffdd54) ![HTML5](https://img.shields.io/badge/html5-%23E34F26.svg?style=for-the-badge&logo=html5&logoColor=white) ![CSS3](https://img.shields.io/badge/css3-%231572B6.svg?style=for-the-badge&logo=css3&logoColor=white) ![Docker](https://img.shields.io/badge/docker-%230db7ed.svg?style=for-the-badge&logo=docker&logoColor=white) -![JavaScript]( https://img.shields.io/badge/JavaScript-F7DF1E?style=for-the-badge&logo=javascript&logoColor=black) +![JavaScript](https://img.shields.io/badge/JavaScript-F7DF1E?style=for-the-badge&logo=javascript&logoColor=black) ![Azure](https://img.shields.io/badge/azure-%230072C6.svg?style=for-the-badge&logo=microsoftazure&logoColor=white) ![SQLite](https://img.shields.io/badge/sqlite-%2307405e.svg?style=for-the-badge&logo=sqlite&logoColor=white) ![Github Actions](https://img.shields.io/badge/GitHub_Actions-2088FF?style=for-the-badge&logo=github-actions&logoColor=white) ![DjangoREST](https://img.shields.io/badge/DJANGO-REST-ff1709?style=for-the-badge&logo=django&logoColor=white&color=ff1709&labelColor=gray) +--- + +## ๐Ÿ“– Table of Contents + +- [About the Project](#-about-the-project) +- [Features](#-features) +- [Prerequisites](#-prerequisites) +- [Installation](#-installation) +- [Project Structure](#-project-structure) +- [API Documentation](#-api-documentation) +- [Screenshots](#-screenshots) +- [Demo](#-demo) +- [Bug Reports](#-bug-reports) +- [Contributing](#-contributing) +- [Acknowledgments](#-acknowledgments) +- [Author](#-author) +- [Support](#-support) + +--- + + +## ๐ŸŽฏ About the Project + +### Problem Statement +Students often struggle to find motivated study partners for specific topics. Traditional methods like asking classmates are inefficient and limit opportunities for collaboration. Many students feel isolated in their learning journey and lack structured spaces to connect with peers who share similar academic goals. + +### Our Solution +**StudyBuddy** is a comprehensive web application that bridges this gap by creating a dynamic community where students can: +- ๐Ÿ” Discover study partners across various academic subjects +- ๐Ÿ‘ฅ Create and join study groups focused on specific topics +- ๐Ÿค Connect with like-minded learners in a structured environment +- ๐Ÿ’ก Share knowledge and collaborate effectively + +Built with modern technologies and deployed on cloud infrastructure, StudyBuddy provides a seamless, responsive experience accessible from any device. The platform emphasizes ease of use while maintaining robust functionality for serious academic collaboration. + +### Tech Stack +- **Backend:** Django, Django REST Framework +- **Frontend:** HTML5, CSS3, JavaScript +- **Database:** SQLite (Development), PostgreSQL (Production-ready) +- **Containerization:** Docker +- **CI/CD:** GitHub Actions +- **Cloud Deployment:** Microsoft Azure + +--- + +## โœจ Features + +- **๐ŸŽฏ Intuitive User Interface** - Simple, clean design that requires minimal learning curve for students of all technical backgrounds +- **๐Ÿณ Docker Containerization** - Fully containerized application ensuring consistency across different environments +- **๐Ÿ”„ CI/CD Pipeline** - Automated testing and deployment using GitHub Actions for rapid development cycles +- **โ˜๏ธ Cloud Deployment** - Production-ready deployment on Microsoft Azure for scalability and reliability +- **๐Ÿ“ฑ Fully Responsive** - Seamless experience across desktop, tablet, and mobile devices +- **๐Ÿ” User Authentication** - Secure login and signup system with personalized user profiles +- **๐Ÿซ Study Room Management** - Create or join study rooms for specific topics and collaborate in real-time +- **๐Ÿ‘ค User Profiles** - Customize your profile with bio, avatar, and academic interests +- **๐Ÿ”Ž Advanced Search** - Find study topics and partners with powerful search and filtering capabilities +- **๐Ÿ“Š Activity Feed** - Stay updated with recent activities and discussions in the community +- **๐Ÿ“ Real-time Messaging** - Communicate with study partners and group members instantly + +--- + +## ๏ฟฝ Prerequisites + +Before you begin, ensure you have the following installed on your machine: + +| Software | Version | Download | +|----------|---------|----------| +| Python | 3.8+ | [python.org](https://www.python.org/downloads/) | +| Git | Latest | [git-scm.com](https://git-scm.com/downloads) | +| pip | Latest | Included with Python | +| Docker *(Optional)* | Latest | [docker.com](https://www.docker.com/products/docker-desktop) | +| Virtual Environment | - | Built-in with Python 3.3+ | + +### System Requirements +- **OS:** Windows, macOS, or Linux +- **RAM:** Minimum 2GB (4GB recommended) +- **Disk Space:** At least 500MB for dependencies and database + +--- + +## ๐Ÿ“ฆ Installation + +Choose one of the following installation methods: + +### Option 1: Local Development Setup (Recommended for Development) + +#### Step 1: Clone the Repository +```bash +git clone https://github.com/abhikalparya/StudyBuddy.git +cd StudyBuddy +``` + +#### Step 2: Create Virtual Environment +```bash +# Windows +python -m venv venv +venv\Scripts\activate + +# macOS/Linux +python3 -m venv venv +source venv/bin/activate +``` + +#### Step 3: Install Dependencies +```bash +pip install -r requirements.txt +``` + +#### Step 4: Apply Database Migrations +```bash +python manage.py migrate +``` + +#### Step 5: Create Superuser (Admin Account) +```bash +python manage.py createsuperuser +``` +Follow the prompts to create your admin account. -## ๐Ÿ“About the project +#### Step 6: Run Development Server +```bash +python manage.py runserver +``` -StudyBuddy is a web application that allows students to find study partners for any topic of their choice. The application is built using the Django framework and is deployed on Azure. The application is also containerized using Docker and is deployed using Github Actions. +The application will be available at `http://localhost:8000` - > StudyBuddy solves the problem of students not being able to find study partners for a particular topic. The application allows students to find study partners for any topic of their choice. The application also allows students to create study groups for a particular topic. +#### Step 7: Access Admin Panel +Navigate to `http://localhost:8000/admin` and log in with your superuser credentials. --- -## ๐Ÿ”ฎFeatures +### Option 2: Docker Installation (Recommended for Deployment) + +#### Prerequisites for Docker +- Docker Desktop installed and running on your machine + +#### Step 1: Clone the Repository +```bash +git clone https://github.com/abhikalparya/StudyBuddy.git +cd StudyBuddy +``` + +#### Step 2: Build Docker Image +```bash +docker build -t studybuddy:latest . +``` + +#### Step 3: Run Docker Container +```bash +docker run -p 8000:8000 -e DEBUG=False studybuddy:latest +``` -- **Easy to use** - The user interface of the project is very simple and easy to use. -- **Used Docker** - The project is containerized using Docker. -- **Implementated CI/CD** - The project is also integrated with GitHub Actions for continuous integration and continuous deployment. -- **Deployed on Azure** - The project is deployed on Azure using GitHub Actions. -- **Responsive** - The project is responsive and can be used on any device. -- **Login/Signup** - The user can login or signup to the application and create a profile. -- **Create/Join Study Rooms** - The user can create/join study rooms for a particular topic and interact with other users. -- **Profile** - The user can view their profile and edit their profile. -- **Search** - The user can search for a particular topic and find study rooms for that topic. +#### Step 4: Access the Application +Open your browser and navigate to `http://localhost:8000` + +#### Optional: Using Docker Compose +Create a `docker-compose.yml` file for production deployment: +```yaml +version: '3.8' +services: + web: + build: . + ports: + - "8000:8000" + environment: + - DEBUG=False + - SECRET_KEY=your_secret_key_here + volumes: + - ./:/app +``` + +Then run: +```bash +docker-compose up --build +``` --- -## ๐Ÿ“ธScreenshots +## ๐Ÿ“ Project Structure + +``` +StudyBuddy/ +โ”œโ”€โ”€ manage.py # Django project management script +โ”œโ”€โ”€ requirements.txt # Python dependencies +โ”œโ”€โ”€ Dockerfile # Docker configuration +โ”œโ”€โ”€ README.md # Project documentation +โ”œโ”€โ”€ LICENSE # Project license +โ”‚ +โ”œโ”€โ”€ StudyBuddy/ # Main Django project settings +โ”‚ โ”œโ”€โ”€ settings.py # Django settings & configurations +โ”‚ โ”œโ”€โ”€ urls.py # Main URL routing +โ”‚ โ”œโ”€โ”€ wsgi.py # WSGI configuration for deployment +โ”‚ โ””โ”€โ”€ asgi.py # ASGI configuration +โ”‚ +โ”œโ”€โ”€ base/ # Main Django application +โ”‚ โ”œโ”€โ”€ models.py # Database models (User, Room, Message) +โ”‚ โ”œโ”€โ”€ views.py # View logic and request handlers +โ”‚ โ”œโ”€โ”€ urls.py # App URL routing +โ”‚ โ”œโ”€โ”€ forms.py # Django forms for user input +โ”‚ โ”œโ”€โ”€ admin.py # Django admin configuration +โ”‚ โ”œโ”€โ”€ apps.py # App configuration +โ”‚ โ”‚ +โ”‚ โ”œโ”€โ”€ api/ # REST API endpoints +โ”‚ โ”‚ โ”œโ”€โ”€ views.py # API view logic +โ”‚ โ”‚ โ”œโ”€โ”€ serializers.py # DRF serializers +โ”‚ โ”‚ โ””โ”€โ”€ urls.py # API routing +โ”‚ โ”‚ +โ”‚ โ”œโ”€โ”€ migrations/ # Database migrations +โ”‚ โ”‚ โ”œโ”€โ”€ 0001_initial.py +โ”‚ โ”‚ โ”œโ”€โ”€ 0002_user_bio_user_name_alter_user_email.py +โ”‚ โ”‚ โ””โ”€โ”€ 0003_user_avatar.py +โ”‚ โ”‚ +โ”‚ โ””โ”€โ”€ templates/ # HTML templates +โ”‚ โ””โ”€โ”€ base/ +โ”‚ โ”œโ”€โ”€ home.html # Homepage +โ”‚ โ”œโ”€โ”€ room.html # Study room details +โ”‚ โ”œโ”€โ”€ profile.html # User profile page +โ”‚ โ”œโ”€โ”€ login_register.html # Authentication pages +โ”‚ โ”œโ”€โ”€ room_form.html # Room creation/editing +โ”‚ โ””โ”€โ”€ ... # Other templates +โ”‚ +โ”œโ”€โ”€ templates/ # Base templates +โ”‚ โ”œโ”€โ”€ main.html # Main base template +โ”‚ โ””โ”€โ”€ navbar.html # Navigation component +โ”‚ +โ””โ”€โ”€ static/ # Static files + โ”œโ”€โ”€ css/ + โ”‚ โ”œโ”€โ”€ style.css + โ”‚ โ””โ”€โ”€ main.css + โ”œโ”€โ”€ js/ + โ”‚ โ””โ”€โ”€ script.js + โ””โ”€โ”€ images/ + โ””โ”€โ”€ icons/ +``` + +### Model Overview + +**User Model** +- Extended Django User model with bio, name, and avatar +- Tracks user activity and study preferences + +**Room Model** +- Study room entity with topic, description, and participants +- Supports many-to-many relationships for users + +**Message Model** +- Stores messages between study group members +- Includes timestamps and author information + +--- + +## ๐Ÿ”Œ API Documentation + +### Base URL +``` +http://localhost:8000/api/ +``` + +### Authentication +All API endpoints support both session and token-based authentication. ->Login Page +### Available Endpoints + +| Method | Endpoint | Description | Auth Required | +|--------|----------|-------------|----------------| +| GET | `/users/` | List all users | Yes | +| GET | `/users//` | Get user details | Yes | +| GET | `/rooms/` | List all study rooms | No | +| GET | `/rooms//` | Get room details | No | +| POST | `/rooms/` | Create a new room | Yes | +| PUT | `/rooms//` | Update room | Yes | +| DELETE | `/rooms//` | Delete room | Yes | +| GET | `/messages/` | List messages | Yes | +| POST | `/messages/` | Create message | Yes | + +### Example API Requests + +#### Get All Rooms +```bash +curl -X GET http://localhost:8000/api/rooms/ +``` + +**Response:** +```json +{ + "count": 2, + "next": null, + "previous": null, + "results": [ + { + "id": 1, + "name": "Python Learning", + "description": "Learn Python programming", + "topic": "Programming", + "participants_count": 5, + "created_at": "2024-01-15T10:30:00Z" + } + ] +} +``` + +#### Create a Room +```bash +curl -X POST http://localhost:8000/api/rooms/ \ + -H "Content-Type: application/json" \ + -H "Authorization: Token YOUR_TOKEN_HERE" \ + -d '{ + "name": "Advanced Django", + "description": "Deep dive into Django ORM", + "topic": "Web Development" + }' +``` + +**Response:** +```json +{ + "id": 3, + "name": "Advanced Django", + "description": "Deep dive into Django ORM", + "topic": "Web Development", + "created_at": "2024-01-20T14:22:00Z", + "created_by": "john_doe" +} +``` + +#### Get User Profile +```bash +curl -X GET http://localhost:8000/api/users/1/ \ + -H "Authorization: Token YOUR_TOKEN_HERE" +``` + +**Response:** +```json +{ + "id": 1, + "username": "john_doe", + "email": "john@example.com", + "bio": "Computer Science student", + "avatar": "https://example.com/avatar.jpg", + "rooms_created": 3, + "rooms_joined": 8, + "joined_date": "2024-01-01T00:00:00Z" +} +``` + +--- + +## ๐Ÿ“ธ Screenshots + +
+๐Ÿ–ผ๏ธ Click to view screenshots + +#### Login Page ![login-page](https://user-images.githubusercontent.com/81465377/216761524-6e08761a-7d7d-40b6-9949-ba2bdc0a5a2a.jpg) ->Signup Page +#### Signup Page ![signup-page](https://user-images.githubusercontent.com/81465377/216761550-02830aa7-c529-413c-b8e1-4436a02fe910.jpg) ->Home Page +#### Home Page ![home](https://user-images.githubusercontent.com/81465377/216761576-5e4621d2-953d-41ad-b8dd-6f5ff65993ef.jpg) ->Profile Page +#### Profile Page ![profile](https://user-images.githubusercontent.com/81465377/216761593-c2085db8-b5a1-4a5b-80df-759d2224ac14.jpg) ->Create Study Room +#### Create Study Room ![create-room](https://user-images.githubusercontent.com/81465377/216761626-c729058a-5609-4478-845c-418fb95c4085.jpg) ->Study Room +#### Study Room ![room](https://user-images.githubusercontent.com/81465377/216761652-35407aa9-1dff-406b-86fc-df1659b6f4d8.jpg) ->Edit Profile +#### Edit Profile ![edit-profile](https://user-images.githubusercontent.com/81465377/216761663-86396871-c40c-41e2-a9b9-3f5a8b0dcee7.jpg) +
+ --- -## ๐ŸŽฅDemo -![Youtube](https://img.shields.io/badge/YouTube-FF0000?style=for-the-badge&logo=youtube&logoColor=white)
-[![Video](https://img.youtube.com/vi/GReHXtIDayg/0.jpg)](https://www.youtube.com/watch?v=GReHXtIDayg) +## ๐ŸŽฅ Demo ---- +Check out our project in action! Watch the video demonstration below: -## ๐Ÿ“‚Installation +![Youtube](https://img.shields.io/badge/YouTube-FF0000?style=for-the-badge&logo=youtube&logoColor=white) -- Clone the repository +[![StudyBuddy Demo Video](https://img.youtube.com/vi/GReHXtIDayg/0.jpg)](https://www.youtube.com/watch?v=GReHXtIDayg) -```bash -git clone https://github.com/abhikalparya/StudyBuddy.git -``` +--- -- Install the requirements +## ๐Ÿ› Bug Reports -```bash -pip install -r requirements.txt -``` +If you encounter any issues or bugs, please help us improve by reporting them: -- Run the server +### How to Report a Bug -```bash -python manage.py runserver +1. **Check Existing Issues** - Search [GitHub Issues](https://github.com/abhikalparya/StudyBuddy/issues) to see if your bug has been reported +2. **Provide Clear Description** - Explain what you were trying to do and what happened +3. **Include Environment Info** - Mention your OS, Python version, and browser (if applicable) +4. **Add Steps to Reproduce** - Provide step-by-step instructions to reproduce the issue +5. **Include Screenshots/Logs** - Attach relevant screenshots or error logs +6. **Submit Issue** - Open a new issue with the title format: `[BUG] Brief description` + +### Report Format +```markdown +**Description:** What went wrong? +**Environment:** OS, Python version, Browser +**Steps to Reproduce:** +1. Step 1 +2. Step 2 +**Expected Behavior:** What should happen? +**Actual Behavior:** What actually happened? +**Screenshots:** [If applicable] ``` + +--- + +## ๐Ÿค Contributing + +We welcome contributions! To contribute to StudyBuddy: + +1. Fork the repository +2. Create a new branch (`git checkout -b feature/amazing-feature`) +3. Make your changes +4. Commit your changes (`git commit -m 'Add amazing feature'`) +5. Push to the branch (`git push origin feature/amazing-feature`) +6. Open a Pull Request + +Please ensure your code follows PEP 8 standards and includes appropriate tests. + +--- + +## ๐Ÿ™ Acknowledgments + +We'd like to thank: + +- **Django Community** - For the robust web framework +- **All Contributors** - Who have helped improve this project +- **Open Source Community** - For the amazing tools and libraries used +- **Our Users** - For using and providing feedback on StudyBuddy + +### Built With + +- [Django](https://www.djangoproject.com/) - Web framework +- [Django REST Framework](https://www.django-rest-framework.org/) - REST API +- [Docker](https://www.docker.com/) - Containerization +- [GitHub Actions](https://github.com/features/actions) - CI/CD +- [Microsoft Azure](https://azure.microsoft.com/) - Cloud hosting + +--- + +## โœ๏ธ Author + +**Abhi Kalparya** + +- GitHub: [@abhikalparya](https://github.com/abhikalparya) +- Email: Contact for inquiries +- LinkedIn: Your LinkedIn profile + +--- + +## ๐Ÿ’ฌ Support + +### Getting Help + +- ๐Ÿ“– **Documentation** - Check the [Wiki](https://github.com/abhikalparya/StudyBuddy/wiki) for detailed guides +- ๐Ÿ› **Issues** - Search [GitHub Issues](https://github.com/abhikalparya/StudyBuddy/issues) for solutions +- ๐Ÿ’ฌ **Discussions** - Join [GitHub Discussions](https://github.com/abhikalparya/StudyBuddy/discussions) for questions +- ๐Ÿ“ง **Email** - Reach out directly with specific questions + +### Support the Project + +If you find StudyBuddy helpful, please consider: +- โญ Starring the repository +- ๐Ÿด Forking and contributing +- ๐Ÿ“ฃ Sharing with your network +- ๐Ÿ’ฐ Sponsoring development (if applicable) + +--- + +## ๐Ÿ“„ License + +This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details. + +### Permissions +- โœ… Commercial use +- โœ… Modification +- โœ… Distribution +- โœ… Private use +- โŒ Liability +- โŒ Warranty + +--- + +## ๐Ÿš€ Roadmap + +### Future Features +- [ ] Advanced notification system +- [ ] Video conferencing integration +- [ ] Study progress tracking +- [ ] AI-powered study partner recommendations +- [ ] Mobile app (iOS/Android) +- [ ] Gamification features (badges, achievements) +- [ ] Group calendar and scheduling +- [ ] File sharing and collaborative documents +- [ ] Study material library +- [ ] Performance analytics dashboard + +--- + +## ๐Ÿ“ž Quick Links + +- [Home Page](http://localhost:8000) +- [Admin Panel](http://localhost:8000/admin) +- [GitHub Repository](https://github.com/abhikalparya/StudyBuddy) +- [Report a Bug](https://github.com/abhikalparya/StudyBuddy/issues/new) +- [Request a Feature](https://github.com/abhikalparya/StudyBuddy/discussions) + +--- + +
+ +**Made with โค๏ธ by Abhi Kalparya** + +โญ Don't forget to star the repository if you found it helpful! + +