---
name: stop-project
description: Stop the development server started with /start-project
---

# /stop-project

Stops the development server started with `/start-project`.

## Steps

### Step 1 — Check that a server is running

```bash
cat .humand/dev.pid 2>/dev/null || echo "not found"
```

If missing or returns `not found`:

> I couldn't find a running server started from here. If you started it manually in another terminal, stop it with `Ctrl + C` in that terminal.

Stop.

### Step 2 — Detect OS and stop the process

```bash
uname -s
```

**Mac/Linux:**
```bash
kill $(cat .humand/dev.pid) 2>/dev/null
rm .humand/dev.pid
```

**Windows (PowerShell):**
```powershell
Stop-Process -Id (Get-Content ".humand/dev.pid") -Force -ErrorAction SilentlyContinue
Remove-Item ".humand/dev.pid" -ErrorAction SilentlyContinue
```

### Step 3 — Confirm the port is free

**Mac/Linux:**
```bash
lsof -ti:3000
```

**Windows:**
```powershell
Get-NetTCPConnection -LocalPort 3000 -ErrorAction SilentlyContinue | Select-Object -ExpandProperty OwningProcess
```

If nothing is returned → port is free.

> Server stopped successfully.

If still in use → inform the user:

> The process was closed but port 3000 still appears to be in use. It may take a few seconds to be released. Let me know if it persists.
