diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..a3de6c7 --- /dev/null +++ b/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2025 Shay Patel + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. \ No newline at end of file diff --git a/README.md b/README.md new file mode 100644 index 0000000..1d2cd8b --- /dev/null +++ b/README.md @@ -0,0 +1,66 @@ +![Screenshot #1 - Homepage](screenshots/HomePage.png) + +# Halflink + +A primitive URL shortener service built powered by Spring Boot, with a NextJS frontend. + +## Tech Stack + +- **Backend**: Spring Boot (Java) +- **Database**: PostgreSQL +- **Frontend**: React (NextJS) with TypeScript + +## Architecture + +The application follows a three-tier architecture: + +- **Presentation Layer**: React-based frontend for URL management +- **Application Layer**: Express.js API server handling business logic +- **Data Layer**: PostgreSQL for URL mappings, interacted with via Spring Boot Data JPA + +## Getting Started + +### Prerequisites + +- Java (tested on OpenJDK 21.0.5) +- Maven (tested on Apache Maven 3.6.3) +- Node.js (v18 or higher, tested on v22.17.0) +- PostgreSQL (v14 or higher, tested on psql 18.1) + +### Installation + +1. Clone the repository: +```bash +git clone https://github.com/0xShay/halflink.git +cd halflink +``` + +2. Configure database variables: +```bash +cd backend/src/main/resources +# Edit application.properties with your database credentials +``` + +3. Build and start the backend server: +```bash +cd backend +mvn package +java -jar target/halflink-1.0.0.jar +``` + +4. Build and start the user interface: +```bash +cd frontend +npm install +npm run build +npm start +``` + +The application will be available at `http://localhost:3000` + +![Screenshot #2 - Successful Shorten](screenshots/LinkShortened.png) +![Screenshot #3 - Manage Link](screenshots/ManageLink.png) + +## License + +This project is open source and available [under the MIT License](LICENSE). diff --git a/screenshots/HomePage.png b/screenshots/HomePage.png new file mode 100644 index 0000000..2d6acff Binary files /dev/null and b/screenshots/HomePage.png differ diff --git a/screenshots/LinkShortened.png b/screenshots/LinkShortened.png new file mode 100644 index 0000000..bf25182 Binary files /dev/null and b/screenshots/LinkShortened.png differ diff --git a/screenshots/ManageLink.png b/screenshots/ManageLink.png new file mode 100644 index 0000000..7025b12 Binary files /dev/null and b/screenshots/ManageLink.png differ