From 43cfef2b121ec4938b16332b72e49b3f1da5545d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Dvo=C5=99=C3=A1k?= <150935816+Dvorinka@users.noreply.github.com> Date: Thu, 22 May 2025 12:08:04 +0200 Subject: [PATCH] Add files via upload --- Makefile | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index fe1d87c..dbf2e55 100644 --- a/Makefile +++ b/Makefile @@ -16,8 +16,14 @@ help: ## Show this help message ##@ Development dev: ## Run both applications in development mode @echo "Starting main application and kontakt service..." + @if lsof -i :$(PORT) > /dev/null; then \ + echo "Error: Port $(PORT) is already in use"; \ + echo "Please stop the existing service or change PORT in Makefile"; \ + exit 1; \ + fi @go run main.go & - @cd kontakt && go run contact-scrape.go + @sleep 2 + @cd kontakt && PORT=$(KONTAKT_PORT) go run contact-scrape.go run: build ## Build and run both applications @echo "Starting $(BINARY_NAME) and $(KONTAKT_BINARY)..."