Skip to content

A File for Forgetting

What is a scratch.md file? How to keep a pinned, uncommitted scratchpad in your code editor for notes and throwaway scripts.

workflow
productivity
dev-tools
writing
vscode

A scratch.md file is an uncommitted Markdown file pinned inside your code editor that acts as disposable digital scrap paper.

Instead of letting a graveyard of unsaved Untitled-1 tabs pile up, it gives you a single persistent buffer for transient work. I first fell in love with this workflow using scratch files in JetBrains DataGrip. When writing throwaway scripts—querying a database, testing API payloads, or dissecting a legacy PowerShell snippet from a 2008 Microsoft forum—you don't want permanence. You just need an uncommitted sandbox.

Most productivity tools demand folders, tags, and database sync. A pinned scratch file asks nothing of you:

  1. Create scratch.md in your project or home directory.
  2. Right-click the tab and select Pin (VS Code pinned tabs stay anchored to the left and survive "Close Other Tabs").
  3. Add scratch.md to your global ~/.gitignore or local .git/info/exclude so git never tracks it.

It won't pollute your git history, trigger code reviews, or accumulate technical debt. It simply provides a distraction-free surface to think with your hands before deciding what deserves to become permanent.

DJ scratching vinyl record

Get new posts by email

New writing in your inbox. Unsubscribe anytime.