CLI · remove

cem remove

Safely delete env keys, custom middlewares and feature modules — with confirmation prompts and automatic unwiring.

Remove an env variable

bash
cem remove env RESEND_API_KEY

Scrubs the key from .env, .env.example and src/app/config/index.ts.

Remove a custom middleware

bash
cem remove middleware requestLogger

Prompts for confirmation, then permanently deletes the middleware file.

Remove a module

bash
cem remove module Task

This will:

  • Prompt for confirmation (the operation is destructive).
  • Delete src/app/modules/Task/.
  • Unwire the import and router registration from src/app/routes/index.ts.

Safety net

Always commit your work first. CEM prompts before destructive operations but there is no undo — clean git state is your safety net.