Skip to main content
Glass features a powerful extension system that allows you to customize and extend the editor’s functionality. Extensions can add language support, themes, icon themes, slash commands, debug adapters, and more.

What Are Extensions?

Extensions are packages that enhance Glass with additional features. They can provide:

Language Support

Add syntax highlighting, code intelligence, and language servers for programming languages

Themes

Customize the editor’s appearance with color themes and icon themes

Slash Commands

Extend the assistant with custom slash commands for specialized tasks

Debug Adapters

Add debugging capabilities for different programming languages and platforms

Context Servers

Integrate Model Context Protocol (MCP) servers for AI capabilities

Snippets

Add code snippets for faster development

Extension Architecture

Glass’s extension system is built on WebAssembly (WASM) for security and performance. Extensions run in isolated sandboxes and communicate with the editor through a well-defined API.

Extension Types

Published Extensions Published extensions are distributed through the Glass extension registry. They are:
  • Downloaded and installed automatically
  • Verified and sandboxed for security
  • Easy to install and update
  • Available to all Glass users
Development Extensions Development (dev) extensions are local extensions you’re building or testing. They:
  • Run from a local directory
  • Support hot-reloading during development
  • Can override published extensions with the same ID
  • Require compilation before installation
When you install a dev extension with the same ID as a published extension, the dev version takes precedence.

Extension Capabilities

Extensions declare their capabilities in an extension.toml manifest file. This includes:

Languages and Grammars

Extensions can add support for new programming languages by providing:
  • Language configuration (file extensions, comment syntax, etc.)
  • Tree-sitter grammars for syntax highlighting
  • Language server integration for code intelligence
Example: The Python extension provides syntax highlighting, IntelliSense, and language server support.

Themes and Icons

Customize Glass’s appearance:
  • Color themes control editor colors, syntax highlighting, and UI elements
  • Icon themes provide custom file and folder icons

Slash Commands

Extend the AI assistant with custom commands. For example:
  • /docs - Search and insert documentation
  • /explain - Explain code in context
  • Custom commands for your workflow

Debug Adapters

Extensions can add debugging support through the Debug Adapter Protocol (DAP):
  • Set breakpoints
  • Step through code
  • Inspect variables
  • View call stacks

Context Servers (MCP)

Model Context Protocol servers provide AI models with external context:
  • File system access
  • Database connections
  • API integrations
  • Custom data sources

Extension Lifecycle

Glass manages extensions automatically:
1

Discovery

Browse available extensions in the Extensions view or through the command palette
2

Installation

Extensions are downloaded, verified, and installed to ~/.config/glass/extensions/installed/
3

Loading

Extensions are loaded on startup and their resources are registered with the editor
4

Updates

Glass checks for updates periodically and can auto-update extensions

Extension Storage

Extensions are stored in specific directories:
~/.config/glass/extensions/
├── installed/          # Published extensions
   ├── extension-id/
   └── another-extension/
├── work/              # Extension runtime data
└── index.json         # Extension index cache

Extension Settings

You can configure extension behavior in your Glass settings:
{
  "extensions": {
    "auto_update": true,
    "auto_install_extensions": {
      "html": true,
      "graphql": true
    }
  }
}

Auto-Installation

Glass can automatically install essential extensions on first launch. This provides out-of-the-box support for common languages and features.

Auto-Updates

By default, Glass automatically checks for and installs extension updates. You can disable this per-extension or globally.
Development extensions are never auto-updated. You must manually rebuild them when needed.

Schema Versions

Extensions declare a schema version in their manifest. Glass supports:
  • Schema version 0: Legacy extensions (deprecated)
  • Schema version 1: Current extension format
Glass only loads extensions with compatible schema versions. This ensures stability as the extension API evolves.

Next Steps

Installing Extensions

Learn how to discover and install extensions

Managing Extensions

Manage, update, and configure your installed extensions

Building Extensions

Create your own extensions for Glass

Extension API

Explore the extension API reference

Build docs developers (and LLMs) love