From e5e0846ddec8c8d30e721a130e5d181b5ae65eff Mon Sep 17 00:00:00 2001 From: Stevan Freeborn Date: Sat, 18 Jul 2026 15:26:06 -0500 Subject: [PATCH] build: stop running emulator process before compiling in run.ps1 --- run.ps1 | 5 ++++- src/main.c | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/run.ps1 b/run.ps1 index 4482e10..4dc3c38 100644 --- a/run.ps1 +++ b/run.ps1 @@ -1,9 +1,12 @@ +Write-Host "[Stopping any running chip instances...]" +Stop-Process -Name chip -ErrorAction SilentlyContinue + Write-Host "[Compiling...]" gcc src/main.c src/chip8.c -o ./.bin/chip.exe -Iinclude -Wall -Wextra -lraylib -lopengl32 -lgdi32 -lwinmm if ($LASTEXITCODE -ne 0) { - Write-Host "[Failed to compiled]"; + Write-Host "[Failed to compile]"; exit 1; } diff --git a/src/main.c b/src/main.c index 7d68f2c..4905449 100644 --- a/src/main.c +++ b/src/main.c @@ -59,7 +59,7 @@ int main(int argc, char *argv[]) { setup_graceful_exit(); if (argc < 2) { - println("You fucked up bro! We need a file to load into memory."); + println("We need a file to load into memory."); println("Usage: chip.exe "); return FILE_NOT_PROVIDED; }