Where Is the Omarchy CLI Executable Located?
The Omarchy CLI executable is located at bin/omarchy within the omacom/omarchy repository, serving as the primary Bash dispatcher that routes user input to appropriate sub-command binaries.
The Omarchy command-line interface is implemented as a modular system where a single dispatcher script coordinates multiple specialized binaries. Understanding the Omarchy CLI executable location is essential for debugging, contributing to the project, or integrating the tool into custom workflows.
Omarchy CLI Executable Location
The primary entry point for the Omarchy command-line interface resides in the repository's bin directory.
The Main Dispatcher Script (bin/omarchy)
The file bin/omarchy acts as the central dispatcher and primary executable. This Bash script determines its own location by setting the OMARCHY_BIN_DIR variable, then scans the same directory for executable files prefixed with omarchy- (such as bin/omarchy-theme or bin/omarchy-update). According to the omacom/omarchy source code, this discovery mechanism enables the CLI to dynamically register available commands without hardcoding them into the dispatcher.
How the CLI Dispatcher Works
The dispatcher employs a metadata-driven architecture to route commands intelligently.
Command Discovery and Registration
When invoked, the bin/omarchy script iterates over every omarchy-* executable in OMARCHY_BIN_DIR. It constructs internal command tables including COMMAND_ROUTE and COMMAND_GROUP by analyzing each binary. This design allows calls like omarchy theme set to resolve automatically to bin/omarchy-theme-set without manual configuration. The routing logic and command registration are validated by the test harness documented in docs/testing.md.
Metadata Parsing
The dispatcher parses special comment markers within sub-command binaries to organize functionality. For example, scripts containing metadata like # omarchy:group=... are categorized accordingly, enabling the help system to display commands in logical groups. This metadata format is documented in agents/skills/command-metadata.md within the repository.
Using the Omarchy CLI
To use the CLI, ensure the repository's bin directory is on your PATH:
export PATH=$OMARCHY_PATH/bin:$PATH
Once configured, you can execute commands directly:
# Display main help information
omarchy --help
# List all available commands
omarchy
# Execute a specific sub-command (e.g., switch to dark theme)
omarchy theme set dark
# Access group commands directly
omarchy update
These examples demonstrate how the dispatcher in bin/omarchy routes your input to the appropriate omarchy-* binary in the same directory.
Summary
-
The Omarchy CLI executable is located at
bin/omarchyin the repository root. -
The dispatcher script dynamically discovers sub-commands by scanning for
omarchy-*binaries in the same directory. -
Command routing relies on metadata parsing (
# omarchy:group=) to build internal tables likeCOMMAND_ROUTEandCOMMAND_GROUP. -
The test harness in
docs/testing.mdvalidates CLI routing and command registration. -
The CLI requires the
bindirectory to be on yourPATHto function as theomarchycommand.
Frequently Asked Questions
Where is the main Omarchy CLI executable located?
The main executable is located at bin/omarchy within the omacom/omarchy repository. This Bash script serves as the primary entry point that loads and coordinates all sub-commands.
What is the purpose of the bin/omarchy dispatcher script?
The bin/omarchy script functions as a command router that determines its own directory location (OMARCHY_BIN_DIR), discovers all omarchy-* executables in that folder, and delegates user input to the appropriate binary based on parsed command tables.
How does Omarchy discover available sub-commands?
The CLI discovers commands by iterating over executable files in OMARCHY_BIN_DIR that match the pattern omarchy-*. It registers each discovered binary into routing tables, allowing the dispatcher to resolve calls like omarchy theme to the corresponding bin/omarchy-theme executable.
Can I run the Omarchy CLI without installing it to PATH?
Yes. Because bin/omarchy is a Bash script, you can invoke it directly using its relative or absolute path (e.g., ./bin/omarchy --help), though adding the bin directory to your PATH enables the standard omarchy command syntax used throughout the documentation.
Have a question about this repo?
These articles cover the highlights, but your codebase questions are specific. Give your agent direct access to the source. Share this with your agent to get started:
curl -s "https://instagit.com/install.md" Maintain an open-source project? Get it listed too →