From 1d8d748a0a1b4d32ec8b1c233e9a58f739ed9391 Mon Sep 17 00:00:00 2001
From: Fabio Manganiello <fabio@manganiello.tech>
Date: Fri, 28 Feb 2025 01:56:20 +0100
Subject: [PATCH] Split Makefile tasks into `backend` and `frontend`

---
 Makefile  | 10 +++++++---
 README.md | 13 ++++++++-----
 2 files changed, 15 insertions(+), 8 deletions(-)

diff --git a/Makefile b/Makefile
index 2ae9c4e..21bea19 100644
--- a/Makefile
+++ b/Makefile
@@ -1,6 +1,10 @@
-all:
+backend:
 	npm install && \
-		npm run build && \
-		cd frontend && \
+		npm run build
+
+frontend:
+	cd frontend && \
 		npm install && \
 		npm run build
+
+all: backend frontend
diff --git a/README.md b/README.md
index 0d4d722..0efcde0 100644
--- a/README.md
+++ b/README.md
@@ -14,6 +14,12 @@ GPSTracker is a simple Webapp that consists of:
 
 ## Building the application
 
+Requirements:
+
+- `node`
+- `typescript`
+- `make`
+
 ```sh
 make
 ```
@@ -22,13 +28,10 @@ Or, if you want to build the backend and the frontend separately:
 
 ```sh
 # Backend
-npm install
-npm run build
+make backend
 
 # Frontend
-cd frontend
-npm install
-npm run build
+make frontend
 ```
 
 ## Configuration