TermLog
Never lose terminal output again. TermLog automatically saves all your VS Code integrated terminal output to log files on disk — per terminal, per day, with timestamps and clean ANSI-stripped text.
Features
- 🔴 Auto-records every command run in the integrated terminal
- 📁 One log file per terminal per day — easy to browse and search
- 🧹 ANSI stripping — clean readable text, no color escape codes
- ⏱️ Timestamps on every command block
- 🔄 Log rotation — automatically rotates when files exceed a size limit
- 📊 Status bar indicator — shows recording state at a glance, click to toggle
- ☁️ Share logs — upload any log to gofile.io and get a shareable link instantly
- ⚡ Zero config — works out of the box with smart defaults
Requirements
TermLog uses VS Code's Shell Integration API (stable, works in published extensions). Shell integration is enabled by default in VS Code 1.87+ for PowerShell, Bash, Zsh, and Fish.
If you see a message that shell integration is not active, go to:
Settings → terminal.integrated.shellIntegration.enabled → true
Commands
| Command |
Description |
TermLog: Toggle Recording |
Pause or resume recording |
TermLog: Open Log for Current Terminal |
Open the log file for the active terminal |
TermLog: Open Log Folder |
Reveal the log folder in your OS file explorer |
TermLog: Share Log (Upload to gofile.io) |
Upload the current log and copy a shareable link |
TermLog: Clear All Logs |
Delete all log files (with confirmation) |
Sharing Logs
Run TermLog: Share Log from the Command Palette:
- A progress spinner appears while the log is uploaded to gofile.io
- The download link is automatically copied to your clipboard
- A notification offers "Open in Browser" or "Copy Link Again"
Files on gofile.io expire after ~10 days of inactivity.
Uses curl.exe (not curl, which is a PowerShell alias).
Settings
| Setting |
Default |
Description |
termLog.outputDirectory |
~/.terminal-logs |
Where to save log files |
termLog.autoRecord |
true |
Start recording automatically on launch |
termLog.addTimestamps |
true |
Add timestamp headers to each command block |
termLog.stripAnsi |
true |
Strip ANSI color/escape codes from saved output |
termLog.maxFileSizeMB |
10 |
Rotate log file after this size (MB) |
Log files are named: <terminal-name>_<YYYY-MM-DD>.log
────────────────────────────────────────────────────────────
[2026-04-27T08:45:39.000Z] Get-ChildItem C:\Windows\System32
────────────────────────────────────────────────────────────
Directory: C:\Windows\System32
...output here...
[command ended]
How It Works
TermLog listens to VS Code's Shell Integration API events:
onDidStartTerminalShellExecution — a command started
execution.read() — async stream of the command output
This approach is stable, low-overhead, and marketplace-publishable — unlike the raw onDidWriteTerminalData proposed API.