Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>DebugPurgeNew to Visual Studio Code? Get it now.
DebugPurge

DebugPurge

Janindu Bandara

|
1 install
| (1) | Free
Simple extension that removes all log/console commands from your project before publishing.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Debug Purger

A lightweight, productivity-boosting VS Code extension that instantly cleans up your codebase by purging leftover debug statements with a single command.

No more hunting down forgotten print statements before a code review!

Features

  • One-Click Cleanup: Instantly removes all console.log statements and variants from JavaScript/TypeScript files.
  • Multi-Language Support: Automatically detects the language of your active file. Works seamlessly with both JavaScript/TypeScript (console.log) and Python (print).
  • Deep Clean: Smart regular expressions wipe out the entire line, leaving no messy trailing semicolons or empty parentheses behind.

How to Use

  1. Open any JavaScript, TypeScript, or Python file that contains debug logs.
  2. Open the VS Code Command Palette:
    • Windows/Linux: Ctrl + Shift + P
    • macOS: Cmd + Shift + P
  3. Type Purge all print/console lines and press Enter.
  4. Watch your debug lines vanish instantly!

Supported Languages & Commands

| Language | Target Cleaned | Web & Scripting JavaScript (javascript) → Removes console.log, console.debug, console.error, console.info, console.warn, console.dir, console.table

TypeScript (typescript) → Removes all console.* variants

React JavaScript (javascriptreact) → Removes console.* within .jsx components

React TypeScript (typescriptreact) → Removes console.* within .tsx components

Python (python) → Removes print() statements

PHP (php) → Removes echo, print, var_dump(), and print_r()

Ruby (ruby) → Removes puts, p, and print

Systems & Desktop Object-Oriented Java (java) → Removes System.out.println() and System.out.print()

C# (csharp) → Removes Console.WriteLine() and Console.Write()

C++ (cpp) → Removes std::cout and std::cerr stream operations

C (c) → Removes printf() functions

Go (go) → Removes fmt.Println(), fmt.Printf(), and fmt.Print()

Rust (rust) → Removes println!, print!, eprintln!, and eprint! macros

Kotlin (kotlin) → Removes println() and print()

Swift (swift) → Removes print() statements

Mobile, Data & Scripting Dart / Flutter (dart) → Removes print() statements

R (r) → Removes print() and cat() statements

Lua (lua) → Removes print() statements

Shell & Database Systems Bash / Zsh (shellscript) → Removes echo outputs

PowerShell (powershell) → Removes Write-Host, Write-Output, and Write-Debug

SQL (sql) → Removes PRINT log triggers

Requirements

  • No external dependencies or configurations required. Works right out of the box!

Known Issues

  • Currently clears the entire matching line. Ensure you do not have critical production code on the exact same line as your debug statements.

Release Notes

1.0.0

  • Initial release.
  • Added core cleanup support for JavaScript/TypeScript (console) and Python (print) statements.

Enjoy a cleaner codebase! 🚀

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2026 Microsoft