PadhaiKarle is a community-driven notes-sharing platform designed for college students. Inspired by AncoreNotes, this app allows students to upload, download, and share study materials seamlessly. With a modern tech stack and robust features, it's the perfect solution for facilitating academic collaboration.
- User Authentication: Secure login via Google authentication.
- Note Upload/Download: Students can upload notes and download them by selecting their branch and semester.
- Top Contributors: A section that highlights the most active contributors.
- Search & Filter: Easily find notes by filtering through branches and semesters.
- Responsive Design: Optimized for both desktop and mobile viewing.
- Web Framework: Next.js
- UI Design: TailwindCSS, shadcn/ui, and Magic UI
- Database: Drizzle ORM + PostgresQL
- Authentication: Lucia
To set up the project locally, follow these steps:
git clone https://github.com/your-username/PadhaiKarle.git
cd PadhaiKarle
You can use your preferred JavaScript package manager to install the necessary dependencies. If you're using `bun`, you can install them with:
bun install
Create a `.env.local` file in the root directory of your project and populate it with the following environment variables:
env
DATABASE_URL="postgresql://<user>:<password>@localhost:5432/<your-db>"
LUCIA_AUTH_URL="http://localhost:3000"
GOOGLE_CLIENT_ID=<your_google_client_id> GOOGLE_CLIENT_SECRET=<your_google_client_secret>
Replace \`<user>\`, \`<password>\`, \`<your-db>\`, \`<your_google_client_id>\`, and \`<your_google_client_secret>\` with your actual database credentials and Google API keys.
Run the following command to set up your database schema:
bun run db:push
To start the development server, run:
bash
bun dev
The app will be available at `http://localhost:3000\`.
Here's a brief overview of the project's structure:
- `/pages`: Contains the main routes of the application.
- `/components`: Reusable UI components used across different pages.
- `/styles`: Global and component-specific styles.
- `/lib`: Utility functions and configurations, including database connections and authentication logic.
- `/public`: Static assets like images and icons.
- `/drizzle`: ORM configurations and database models.
- Environment Variables: Sensitive information like API keys and database credentials are stored in environment variables to avoid accidental exposure.
- Authentication: Implemented using Lucia, ensuring secure and scalable user authentication.
- Input Validation: Proper validation is implemented to prevent SQL injection and other common vulnerabilities.
For more detailed information about the tools and technologies used, refer to their official documentation:
- Next.js Documentation
- TailwindCSS Documentation
- shadcn/ui Documentation
- Drizzle ORM Documentation
- Lucia Documentation
Contributions are welcome! If you'd like to contribute, please follow these steps:
- Fork the repository.
- Create a new branch: `git checkout -b feature/your-feature-name`.
- Make your changes and commit them: `git commit -m 'Add some feature'`.
- Push to the branch: `git push origin feature/your-feature-name`.
- Open a pull request.
This project is licensed under the MIT License - see the LICENSE file for details.
If you have any questions or feedback, feel free to reach out to me at [email protected].