Skip to content
| Marketplace
Sign in
Visual Studio Code>Programming Languages>EnvScopeNew to Visual Studio Code? Get it now.
EnvScope

EnvScope

Deepak0135

|
1 install
| (1) | Free
Validate .env files, infer schemas, flag missing keys, and detect secret leaks. Fully offline.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

EnvScope

EnvScope is an offline-first, zero-dependency VS Code extension designed to catch environment drift, malformed configurations, and credential leaks directly inside your editor in real time.

Built natively on the VS Code Extension API using only Node.js runtime primitives, EnvScope guarantees that your secret tokens never leave your local workspace—zero telemetry, zero external APIs, and zero background analytics.


Key Features

  • Shannon Entropy Leak Detection: Computes character randomness scores in real time to flag high-entropy credentials (AWS keys, OpenAI/Gemini tokens, private keys) before they get committed to public repositories or template files.
  • Schema Drift & Missing Key Alerts: Compares your active .env file against .env.example (or template schemas) and triggers native VS Code Diagnostics for missing or extra variables.
  • Type & Contract Inference: Automatically infers basic types (number, boolean, url, string) from schemas and underlines mismatched values.
  • Offline-First Security: Complete functional isolation. No external npm libraries, no outbound HTTP calls, and no analytics collection.
  • Interactive Dashboard: Press Cmd+Shift+P (macOS) or Ctrl+Shift+P (Windows/Linux) and run EnvScope: Open Dashboard to inspect your workspace environment health in a clean, sandboxed Webview interface.

How It Works

  1. Local Diagnostic Scanner: When you open any .env* file, EnvScope registers an active diagnostic collection using vscode.languages.createDiagnosticCollection.
  2. Entropy Analysis: Each variable value is evaluated using Shannon's entropy formula: $$H(X) = -\sum_{i=1}^{n} P(x_i) \log_2 P(x_i)$$ Values scoring above the threshold (typically > 4.2 bits/char) are immediately underlined with actionable warnings in your editor and the Problems tray.
  3. Workspace Cross-Referencing: EnvScope reads neighboring .env.example definitions to ensure your local runtime matches team configurations.

Usage

  1. Open any workspace containing environment files (.env, .env.example, .env.local).
  2. Type in your .env file—diagnostics will update automatically as you edit.
  3. Hover over variable names to view inferred types and entropy statistics.
  4. Access commands via the Command Palette (Ctrl+Shift+P / Cmd+Shift+P):
    • EnvScope: Open Dashboard — View workspace environment parity and active issues.

Configuration

EnvScope runs out of the box with sensible defaults. You can customize behavior via VS Code Settings (settings.json):

{
  "envscope.enableEntropyCheck": true,
  "envscope.entropyThreshold": 4.2,
  "envscope.templateFile": ".env.example"
}
  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
  • Your Privacy Choices
  • Consumer Health Privacy
© 2026 Microsoft