Keyboard Shortcuts - ArunPrakashG/native-launcher GitHub Wiki

Keyboard Shortcuts Reference

Complete keyboard shortcut reference for Native Launcher.

Table of Contents

Global Shortcuts

These are configured in your Wayland compositor, not in Native Launcher itself.

Shortcut Action Configuration
Super+Space Open launcher Recommended (see Compositor Integration)
Alt+Space Open launcher Alternative option
Ctrl+Space Open launcher Alternative option

Note: You can configure any key combination in your compositor.

Navigation

Keyboard shortcuts while Native Launcher is open:

Shortcut Action
/ Navigate through results
Enter Launch selected application/action
Ctrl+1 Execute first result (no navigation needed)
Escape Close launcher
Ctrl+Enter Search the web with current query
Ctrl+P Pin/Unpin selected application

Search & Launch

Basic Search

Action How To
Search applications Just start typing
Clear query Ctrl+U or Ctrl+A + Backspace
Select all text Ctrl+A

Launch Modes

Shortcut Action
Enter Launch selected item
Ctrl+1 Execute first result - Fast workflow without needing to navigate
Ctrl+Enter Web search - Opens browser with query
Ctrl+P Pin/Unpin - Toggle favorite for app

Example workflow:

1. Type: "rust wayland"
2. Press Ctrl+Enter
3. Browser opens Google search for "rust wayland"

Plugin Shortcuts

Different plugins respond to specific keyboard combinations and command prefixes.

Command Prefix Reference

Use @ commands to search specific plugins directly:

Prefix Plugin Description Example
@app <query> Applications Search applications only @app firefox
@tabs, @history Browser History Search browser history & bookmarks @tabs github
@cal <expression> Calculator (Basic) Calculate mathematical expressions @cal 2+2*5
@convert <query> Calculator (Adv) Unit conversions @convert 5 km to miles
@time <query> Calculator (Adv) Time calculations @time 1 hour ago
@currency <query> Calculator (Adv) Currency conversions @currency 100 USD to EUR
@clip [query] Clipboard History Access clipboard history @clip password
@code, @zed, @editor Editors Search editor workspaces @code my-project
@emoji <keyword> Emoji Picker Search and copy emojis @emoji smile
@files Files Search recent files and directories @files document
@launcher, @updater Launcher Self-update and maintenance @launcher update
@shell <cmd> or $ <cmd> Shell Execute shell commands @shell ls -la or $ pwd
@ssh <host> SSH Connect to SSH hosts @ssh server
@theme <name> Theme Switcher Switch application themes @theme dracula
@web <query> Web Search Search the web @web rust tutorial
@workspace <query> Editors Search editor workspaces @workspace my-app

Without prefixes: When you search without a prefix, all plugins participate and results are sorted by relevance and priority.

Web Search Plugin

Shortcut Action Example
Ctrl+Enter Search with Google Any query → Google search
Prefix query Use specific engine google rust, ddg privacy, wiki linux

Supported search engines:

  • google <query> - Google Search
  • ddg <query> - DuckDuckGo
  • wiki <query> - Wikipedia
  • github <query> - GitHub
  • youtube <query> - YouTube

Examples:

google rust wayland      → Ctrl+Enter → Google search
ddg privacy tools        → Ctrl+Enter → DuckDuckGo search
wiki operating system    → Ctrl+Enter → Wikipedia search
firefox                  → Ctrl+Enter → Google search for "firefox"

Calculator Plugin

Basic Calculator

Prefix Action Example
@cal <expr> Calculate @cal 2+2, @cal sqrt(16), @cal 5*9
Type expression Calculate 2+2, sqrt(16), 5*9 (without prefix)
Enter Copy result Result copied to clipboard

Note: Calculator automatically detects math expressions, so the @cal prefix is optional.

Advanced Calculator

Prefix Action Example
@time <query> Time calculation @time 1 hour ago, in 5 hours
@convert <query> Unit conversion @convert 5 km to miles
@currency <query> Currency conversion @currency 100 USD to EUR
Type natural query Smart detection 1 hour ago, 5 km to miles
Enter Copy to clipboard Copies result + shows notification

Time Calculations:

  • Past: 1 hour ago, 5 days ago, 350 days ago
  • Future: in 2 hours, 5 weeks from now
  • Timezone: now in UTC

Unit Conversions:

  • Time: 150 days to years, 500 minutes to hours
  • Distance: 5 km to miles, 100 feet to meters
  • Weight: 100 pounds to kg, 500 grams to ounces
  • Temperature: 32 fahrenheit to celsius

Currency: 100 USD to EUR, 50 GBP to JPY (10+ currencies supported)

See Advanced Calculator for complete guide.

Launcher Plugin

The Launcher Plugin provides self-management commands for updating and maintaining Native Launcher itself.

Prefix Action Example
@launcher Show all options @launcher
@launcher update Update Native Launcher @launcher update
@launcher restore Restore from backup @launcher restore
@launcher uninstall Uninstall launcher @launcher uninstall
@updater (alias) Same as @launcher @updater update
@native-launcher(alias) Same as @launcher @native-launcher

Available Actions:

  • Update - Runs the install.sh script from the repository to update/reinstall the launcher

    • Opens in external terminal for interactive updates
    • Preserves your configuration and themes
    • Shows installation progress
  • Restore - Runs the restore.sh script to restore from previous backups

    • Lists all available backups with timestamps
    • Shows what's included in each backup
    • Lets you select which backup to restore
    • Restores binary, config, plugins, cache, and data
  • Uninstall - Runs the uninstall.sh script to remove Native Launcher

    • Removes binary from ~/.local/bin
    • Removes system-wide symlink (if created)
    • Asks for confirmation before removing config/data
    • Can preserve backups for later reinstallation

Examples:

# Quick update
@launcher update → Enter → Terminal opens with install script

# Restore from backup
@launcher restore → Enter → Interactive backup selection

# View all launcher commands
@launcher → Shows: Update, Restore, Uninstall options

Note: All launcher commands require terminal access and will open in your default terminal emulator.

Shell Plugin

Prefix Action Example
@shell <command> Execute command @shell ls -la
$ <command> Execute command $ pwd
Enter Run in terminal Opens command in terminal

Note: Both @shell and $ work the same way - use whichever you prefer!

SSH Plugin

Prefix Action Example
@ssh <host> Connect to host @ssh server.com
@ssh List all SSH hosts @ssh (no query)
Enter Connect in terminal Opens SSH session

Editors Plugin

Prefix Action Example
@code <query> Search VS Code workspaces @code launcher
@zed <query> Search Zed workspaces @zed my-project
@editor <query> Search all workspaces @editor website
Enter Open in editor Opens workspace in editor

Detected editors: VS Code, VSCodium, Sublime Text, Zed

File Browser Plugin

Prefix Action Example
@files <query> Search files @files document.pdf
/ Browse path /home/user/Downloads
~ Browse home ~/Documents

Applications Plugin

Prefix Action Example
@app <query> Search apps only @app firefox
No prefix Search all (default) firefox

Note: Applications plugin participates in all searches by default with highest priority.

Pins/Favorites

  • Toggle pin with Ctrl+P on any application result.
  • Pinned apps show a coral star overlay on their icon.
  • On empty query, pinned apps are shown first, followed by most-used apps.
  • Pins are persisted to ~/.local/share/native-launcher/pins.json.

Custom Shortcuts

You can create custom shortcuts in your plugins. See Plugin Development for details.

Example: Custom Calculator Shortcut

// Plugin can handle "=" key to evaluate expression
if event.key == Key::equal && !event.has_ctrl() {
    return KeyboardAction::Execute { /* copy result */ };
}

Example: Custom Alt+Enter Behavior

// Plugin can handle Alt+Enter for alternative action
if event.key == Key::Return && event.has_alt() {
    return KeyboardAction::OpenUrl(custom_url);
}

Modifier Keys Reference

Modifier Linux Name Common Key
Ctrl Control_L / Control_R Ctrl
Shift Shift_L / Shift_R Shift
Alt Alt_L / Alt_R Alt
Super Super_L / Super_R Windows/Cmd key

Advanced Usage

Chaining Commands

Some plugins support command chaining:

@shell cd ~/projects && ls     # Change directory and list
$ git status && git log -1     # Multiple git commands

Search Modifiers

Pattern Behavior Example
@<plugin> query Command prefix (targets specific plugin) @code project, @cal 5*5
$ command Shell command shortcut $ ls -la
No prefix Global search (all plugins) firefox, calculator

Command Prefix Benefits:

  • Faster results (only searches one plugin)
  • More focused results (no mixing of different types)
  • Better for automation and scripting

Fuzzy Search

Native Launcher uses intelligent fuzzy matching:

fir     → Matches "Firefox"
vsc     → Matches "VS Code"
gim     → Matches "GIMP"

No need for exact matches!

Tips & Tricks

Speed Up Searches

  1. Use command prefixes - @code only searches workspaces, @app only searches apps - much faster than global search
  2. Use $ for shell - Quick shell commands: $ pwd, $ git status
  3. Learn abbreviations - Common apps have short triggers: ff → Firefox, vsc → VS Code
  4. Use Ctrl+Enter - Quick web search without waiting for results

Plugin-Specific Workflows

Quick Calculator:

Super+Space → @cal 2+2*5 → Enter

Shell Command:

Super+Space → $ git status → Enter

SSH Connection:

Super+Space → @ssh myserver → Enter

Workspace Search:

Super+Space → @code launcher → ↓ → Enter

Keyboard-Only Workflow

1. Super+Space          → Open launcher
2. Type query           → Search
3. ↓↓ (if needed)       → Navigate to result
4. Enter                → Launch

No mouse needed!

Web Search Workflow

1. Super+Space          → Open launcher
2. Type "rust tutorial" → See results
3. Ctrl+Enter           → Search web immediately

Skip waiting for app results!

Multi-Step Launch

1. Super+Space          → Open launcher
2. Type "code"          → Find VS Code
3. ↓↓                   → Navigate to workspace
4. Enter                → Open workspace

Customization

Changing Global Hotkey

Edit your compositor config:

Sway (~/.config/sway/config):

# Change from Super+Space to Alt+D
bindsym $mod+d exec native-launcher

Hyprland (~/.config/hypr/hyprland.conf):

# Change to Ctrl+Alt+Space
bind = CTRL ALT, SPACE, exec, native-launcher

See Compositor Integration for more examples.

Plugin-Specific Shortcuts

Configure in ~/.config/native-launcher/config.toml:

[plugins.web_search]
default_engine = "ddg"  # Use DuckDuckGo by default

[plugins.ssh]
default_terminal = "kitty"  # Use kitty for Alt+Enter

See Configuration for all options.

Keyboard Event System

Native Launcher uses a plugin-driven keyboard event system:

  1. Key press is captured
  2. Event is created with context (key, modifiers, query, selection state)
  3. Event is dispatched to plugins in priority order
  4. First plugin to handle the event wins

This means:

  • ✅ Plugins own their shortcuts
  • ✅ No conflicts (priority-based)
  • ✅ Easy to add new shortcuts
  • ✅ Context-aware (plugins see current state)

See Architecture for technical details.

Next Steps

⚠️ **GitHub.com Fallback** ⚠️