LogScope - High Performance Android Logcat VisualizerLogScope is a VS Code extension designed for Android developers, providing high-performance log streaming, intelligent filtering, workflow automation, and code navigation. It aims to replace traditional command-line Logcat and Android Studio Logcat, allowing you to seamlessly debug Android devices within VS Code.
✨ Core Features1. 🚀 Extreme Performance
2. 🔍 Powerful Filter EngineSupports multiple filtering syntaxes to meet complex debugging needs:
3. 📱 Device Management
4. ⚡ Workflow AutomationLogScope allows you to define a series of automated tasks via configuration files, such as "Clear Data -> Restart App -> Capture Specific Logs". Configuration MethodCreate a Example Configuration (
|
| Syntax | Description | Example |
|---|---|---|
tag:<value> |
Match Tag | tag:ActivityManager |
pid:<id> |
Match Process ID | pid:12345 |
tid:<id> |
Match Thread ID | tid:9876 |
level:<char> |
Match Level (V/D/I/W/E/F) | level:E |
<text> |
Fuzzy match message content | NullPointerException |
-<filter> |
Exclude condition | -tag:SurfaceFlinger |
! |
Exclude (Same as above) | !pid:0 |
Tip: Multiple conditions separated by spaces indicate an AND relationship. For performance optimization, multiple positive conditions of the same type (like
tag:A tag:B) are usually treated as an OR relationship.
Resizing Columns
- Hover over the header separator line, and when the cursor changes to resize style, drag to adjust the width of columns like
Time,PID,TID,Tag. Double-click the separator to reset.
⚙️ Configuration
Configure LogScope in VS Code Settings (settings.json):
{
// ADB Logcat base command parameters
"logScope.logcatCommand": "logcat -v threadtime",
// Path Mapping: Map server paths in logs to local project paths
// Format: "Absolute path prefix in log": "${workspaceFolder}/Local relative path"
"logScope.pathMapping": {
"/proc/self/cwd/": "${workspaceFolder}/src/cpp/",
"com.example.app": "${workspaceFolder}/app/src/main/java/"
},
// Font Size
"logScope.fontSize": 12,
// Font Family
"logScope.fontFamily": "'JetBrains Mono', 'Courier New', monospace"
}
⌨️ Shortcuts
- Ctrl+L (Mac: Cmd+L): Clear current logs
- Ctrl+F: Focus filter input box
- Space: Pause/Resume log scrolling
🛠️ FAQ
Q: Cannot connect to device?
A: Please ensure adb is configured in your system environment variables, or that adb devices runs in the terminal. LogScope reuses the system's ADB connection.
Q: Cannot find specific logs?
A: Please check if level filtering is enabled, or if there are typos in the filter words. Try clearing all filters to view the raw stream.
Q: Why are logs not real-time? A: When logs are generated extremely fast, we perform slight buffering to ensure interface smoothness. The latency is usually in milliseconds and imperceptible to the naked eye.
LogScope —— Making Android Log Debugging Simpler and More Professional.
