Extension Icon

Vim Leader Key

Vim-style leader key for launching apps, running commands, and triggering actions with key sequences
Overview

Leader Key for Raycast

A Vim-style leader key extension for Raycast that enables quick navigation through hierarchical menus using single keystrokes. Organize your apps, commands, and shortcuts into logical groups for lightning-fast access.

Features

πŸ—‚οΈ Hierarchical Organization

  • Nested Groups: Create folders to organize related actions
  • Single-Key Navigation: Navigate with individual keystrokes (no chord combinations)
  • Breadcrumb Navigation: Visual indication of your current location
  • Auto-Reset: Configurable timeout to return to root menu

πŸš€ Action Types

  • Applications: Launch apps with file-based or name-based targeting
  • URLs: Open websites or Raycast deeplinks
  • Folders: Open directories in Finder
  • Commands: Execute shell commands

βš™οΈ Configuration Management

  • Import/Export: Share configurations via JSON files
  • Legacy Migration: Automatic upgrade from flat key sequences
  • Conflict Detection: Prevents duplicate keys within groups
  • Visual Editor: Intuitive forms for adding and editing items

🎯 Smart UI/UX

  • Type-based Grouping: Items organized by type for easy scanning
  • Dynamic Icons: App-specific icons and contextual indicators
  • Real-time Search: Type to navigate, with context-aware hints
  • Comprehensive Actions: Edit, delete, add, and navigate with keyboard shortcuts

Quick Start

  1. Install the extension in Raycast
  2. Run Leader Key command
  3. Press any key to see available actions
  4. Use ⌘N to add new actions or βŒ˜β‡§N to add groups

Default Configuration

The extension comes with a basic setup:

c β†’ Calculator
a β†’ Applications/
  β”œβ”€β”€ f β†’ Finder
  └── t β†’ Terminal

Usage Examples

Simple Actions

  • Press c to open Calculator
  • Press a then f to open Finder via Applications group

Creating Groups

  1. Press βŒ˜β‡§N to create a new group
  2. Set a key (e.g., d for "Dev Tools")
  3. Add actions to the group using ⌘N

Action Types

Applications:

  • Use app bundle paths: /Applications/Visual Studio Code.app
  • Or simple names: Visual Studio Code

URLs:

  • Websites: https://github.com
  • Raycast deeplinks: raycast://extensions/raycast/system/quit-all-applications

Commands:

  • Shell scripts: open ~/Downloads
  • Complex commands: git status && git pull

Configuration

Preferences

  • Auto-Reset Timeout: Enable/disable automatic return to root
  • Timeout Duration: Set timeout between 2.5-6 seconds

Import/Export

  1. Export: Use Export Config command to save your setup
  2. Import: Use Import Config command to load shared configurations
  3. Share: JSON files are compatible across installations

JSON Format

{
  "type": "group",
  "actions": [
    {
      "key": "c",
      "type": "application",
      "label": "Calculator",
      "value": "/System/Applications/Calculator.app"
    },
    {
      "key": "a",
      "type": "group",
      "label": "Applications",
      "actions": [
        {
          "key": "f",
          "type": "application",
          "label": "Finder",
          "value": "/System/Library/CoreServices/Finder.app"
        }
      ]
    }
  ]
}

Keyboard Shortcuts

Navigation

  • Any Key: Navigate to action or group
  • Backspace: Go back to parent group
  • Escape: Reset to root menu

Management

  • ⌘N: Add new action
  • βŒ˜β‡§N: Add new group
  • ⌘E: Edit current item
  • ⌘⌫: Delete current item
  • ⌘C: Copy action value

Migration from v1

If you used the previous version with flat key sequences, your configuration will be automatically migrated to the new hierarchical format. Multi-character sequences like ac become nested structures (a β†’ c).

Tips & Best Practices

Organization Strategies

  • By Category: Group similar apps (dev/, media/, utils/)
  • By Frequency: Put most-used items at root level
  • By Workflow: Create project-specific groups

Key Selection

  • Use mnemonic keys (c for Calculator, t for Terminal)
  • Keep frequently used actions on single keystrokes
  • Use logical groupings (a for Applications, u for URLs)

Performance

  • The extension has minimal startup time
  • Nested navigation is instant
  • Large configurations (100+ items) perform well

Troubleshooting

Actions not working?

  • Check file paths for applications
  • Verify URLs are complete and valid
  • Test shell commands in Terminal first

Keys not responding?

  • Clear configuration and rebuild if migration failed
  • Check for key conflicts within groups
  • Ensure timeout isn't too short

Import/Export issues?

  • Validate JSON format
  • Check that all required fields are present
  • Use Export to see proper format

Inspiration & Compatibility

This Raycast extension was inspired by mikker's Leader Key app for macOS. The JSON configuration format is designed to be compatible, allowing easy migration and sharing of configurations between both tools.

While this extension brings the leader key concept to Raycast with additional features like real-time navigation and Raycast-specific integrations, it maintains the same hierarchical philosophy that makes mikker's original app so effective.

Contributing

This extension is part of the Raycast ecosystem. For issues or feature requests, please check the repository or contact the maintainer.

License

MIT