elvish

Document the Elvish editor API, completion pipeline, and startup configuration.

1.4k|36|Updated Mar 17, 2020
One-click install
npx skills add https://github.com/carapace-sh/carapace --skill elvish
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: elvish
Source: https://github.com/carapace-sh/carapace/tree/main/skills/elvish
Command: npx skills add https://github.com/carapace-sh/carapace --skill elvish

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

The Elvish skill provides a structured, self-contained reference for understanding and extending Elvish's interactive environment, including the completion system, editor API, modules, and startup configurations.

Core Features & Use Cases

  • Comprehensive coverage of the editor API (edit: namespace, modes, prompts, hooks) and the completion engine (arg-completers, matchers, complex-candidate, and the pipeline) to enable deep customization.
  • Practical guidance for carapace-style integrations, bootstrapping custom completions, and configuring rc.elv for tailored workflows.
  • Real-world use cases include building command-specific arg-completers, crafting rich UI candidates with styling, and wiring startup and module loads for a polished developer workflow.

Quick Start

Load the included SKILL.md and related references to begin exploring Elvish editor internals and completion workflows.

Frequently Asked Questions about elvish

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I configure arg-completers for custom commands in Elvish?

To configure arg-completers in Elvish, you register completion logic through the editor API to define command-specific candidates. The Elvish completion pipeline processes these registrations to generate tailored suggestions for your interactive sessions.

How does the Elvish completion pipeline and matcher system work?

The Elvish completion pipeline uses matchers to filter and rank candidates generated by arg-completers. Custom matchers allow you to control how completion candidates are evaluated and displayed within the editor environment.

What is the best way to customize the Elvish editor namespace for prompts and hooks?

Customizing the Elvish editor involves using the edit: namespace to define prompts, hooks, and modes. This API allows deep modification of the interactive environment, enabling tailored UI styling and workflow integration.

How do I set up startup configuration and module loading in rc.elv?

You configure Elvish startup behavior by defining module loads and environment setup in the rc.elv file. This startup configuration wires your custom completions, matchers, and editor settings into each interactive session.

Can I apply custom styling to completion candidates in Elvish?

Yes, Elvish supports styling for completion candidates through the complex-candidate mechanism. This allows you to attach UI attributes to candidates, creating a rich and visually distinct completion menu.

Does carapace-style completion integration work with Elvish modules?

Carapace-style integrations can be bootstrapped within Elvish modules to provide structured command completions. This approach leverages the editor API and arg-completer registration to deliver consistent completion behavior across your workflow.