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

Redline

g3nx89

|
4 installs
| (0) | Free
Non-destructive, high-precision context injection for AI Coding Agents.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Redline: AI Context Injection for VS Code

Redline is a VS Code extension designed to bridge the gap between human intent and AI Agent execution. It allows developers to mark specific lines of code with detailed instructions, creating a persistent "meta-layer" of context that travels with your codebase without cluttering the source files with comments.

Build Status

🚀 Key Features

  • Non-Destructive Annotation: Instructions are stored in a parallel .redline directory (.json sidecars), keeping your source code clean.
  • Visual Decorations: Annotated lines are highlighted directly in the editor with a distinct style, so you never lose track of pending tasks.
  • Traceability: Automatically captures the Git identity of the creator (user.name), timestamp, and resolution status.
  • Management Sidebar: A dedicated "Redline" view in the Activity Bar lists all active instructions, allowing for quick navigation and one-click resolution.
  • Context Export: Generate structured Markdown briefings optimized for AI Agents (e.g., Gemini, ChatGPT, Claude). Includes:
    • Focus Masking: Automatically highlights exact character ranges (e.g., ^^^^) to direct AI attention.
    • Prompt Profiles: built-in templates for "Strict Refactoring", "Documentation", or "General Assistance".

📦 Installation

  1. Clone the repository:
    git clone https://github.com/g3nx89/redline.git
    
  2. Open in VS Code:
    code redline
    
  3. Install dependencies:
    npm install
    
  4. Run the extension (F5 or "Run Extension" launch config).

🛠️ Usage

Adding an Instruction

  1. Select the code you want to annotate.
  2. Open the Command Palette (Ctrl+Shift+P / Cmd+Shift+P).
  3. Run Redline: Add Instruction.
  4. Type your instruction (e.g., "Refactor this function to be async").

Managing Instructions

  • Open the Sidebar: Click the Redline icon in the activity bar.
  • Jump to Code: Click any item to open the file and scroll to the location.
  • Resolve: Click the checkmark icon to mark an instruction as resolved. It will disappear from the default view (but remains in history).

Exporting for AI

  1. Run Redline: Export Briefing.
  2. Select Scope: Current File or Workspace.
  3. Select Profile:
    • Default: Standard context injection.
    • Strict Refactor: Explicitly forbids logic changes.
    • Docs Only: Requests JSDoc/Comments only.
  4. Copy the generated Markdown into your AI chat window.

🏗️ Architecture

Redline operates on a "Sidecar" pattern:

  • Source: src/app.ts
  • Sidecar: .redline/src/app.ts.json

This ensures that instructions can be committed to Git and shared with the team, but do not interfere with compilers or linters.

Key Components

  • SidecarService: Manages file system I/O for the .redline folder.
  • DecorationService: Renders the visual highlights in the editor.
  • PayloadGenerator: Compiles instructions and source code into the final AI prompt.
  • SidebarProvider: Webview interface for managing the instruction list.

✅ Quality Assurance

Run the test suite to verify functionality:

npm test

This runs:

  • Unit Tests: Verifies logic for path generation and markdown formatting.
  • Integration Tests: Runs a real instance of VS Code to verify End-to-End flows (Add -> Resolve).

📄 License

MIT

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