---
title: "Discussion on \"How to stop Replit Agent and Lovable from nuking your working code (5 copy-paste prompts)\" | Hashnode"
description: "Discussion on \"How to stop Replit Agent and Lovable from nuking your working code (5 copy-paste prompts)\". 5 copy-paste prompts that stop Replit Agent and Lovable from rewriting code that already works: scope fences, plan-first, diagnose-first, locks."
url: "https://hashnode.com/posts/how-to-stop-replit-agent-and-lovable-from-nuking-your-working-code-5-copy-paste-prompts/6ab748375622de964b40f073"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [How to stop Replit Agent and Lovable from nuking your working code (5 copy-paste prompts)](https://pocketstudio.hashnode.dev/how-to-stop-replit-agent-and-lovable-from-nuking-your-working-code-5-copy-paste-prompts?utm_source=hashnode&utm_medium=feed)

5 copy-paste prompts that stop Replit Agent and Lovable from rewriting code that already works: scope fences, plan-first, diagnose-first, locks.

Sep 26 · 7 min read · pocketstudio.hashnode.dev  
Read the article

-   [#replit](https://hashnode.com/tag/replit)
-   [#lovable](https://hashnode.com/tag/lovable)
-   [#vibe-coding](https://hashnode.com/tag/vibe-coding)
-   [#adhd](https://hashnode.com/tag/adhd)
-   [#ai](https://hashnode.com/tag/ai)

## Written by

[PocketStudio](https://hashnode.com/@pocketstudio)

@pocketstudio

  
[View profile](https://hashnode.com/@pocketstudio)

Copy-paste prompts for neurospicy vibe-coders. Author of The Vibe-Code Prompt Bible.

PocketStudio makes copy-paste prompt packs for ADHD/autistic/neurospicy builders using Replit Agent and Lovable. Author of The Vibe-Code Prompt Bible: https://vibe-code-prompt-bible.surge.sh/

## Responses 1

Markdown supported · ⌘↵ to post

[Mythex](https://hashnode.com/@mythex)

[Sep 26](https://hashnode.com/posts/how-to-stop-replit-agent-and-lovable-from-nuking-your-working-code-5-copy-paste-prompts/6ab748375622de964b40f073/comment/6ab764e8cd7eeec5dc2b2cfd)

Prompt 3's "what changed since then" field is the underrated one here. One addition worth making: paste the diff of that last change, not a description of it. People describe what they asked for, and the bug is usually in what the agent did beyond that, like the drive-by edit in a file nobody mentioned. With the actual diff in the prompt, the model stops guessing where to look.

A small caveat on Prompt 1, from building an AI app builder myself (disclosure: I work on Mythex): the forbidden-files list works best when it's short. A long list quietly reads as "everything not listed is fair game." Naming the two or three files that must not change, and letting "STOP and ask" cover the rest, tends to hold up better.
