一个可被黑客攻击的 cli/tui 启动程序,专为以键盘为中心的 WM 用户而设计,具有 vi 和 emacs 键绑定、ansi 装饰等功能
一个可被黑客攻击的 cli/tui 启动程序,专为以键盘为中心的 WM 用户而设计,具有 vi 和 emacs 键绑定、ansi 装饰等功能
A very hackable app launcher, designed for keyboard-centric wm users. It is blazingly fast, supports vi and emacs keybinds, and can be decorated with ansi color codes, sixel or kitty image protocols.
The core concept is making these behaviours possible:
It's recommended to setup a dedicated desktop app launcher as a module, like fsel or sway-launcher-desktop. Some helper scripts can be found in the contrib folder, modules in wiki.
Workflow
External editor, list selection, and cheatsheet
paru -S otter-launchergit clone https://github.com/kuokuo123/otter-launcher /tmp/otter-launcher
cd /tmp/otter-launcher
cargo build --release
mkdir -p $HOME/.config/otter-launcher
cp /tmp/otter-launcher/config_example/config.toml $HOME/.config/otter-launcher/config.toml
sudo cp /tmp/otter-launcher/target/release/otter-launcher /usr/bin/Otter reads from $HOME/.config/otter-launcher/config.toml. If missing, it looks into /etc/otter-launcher/config.toml, which is included in the AUR installation. Use the '--config' or '-c' flag to specify your preferred path otherwise.
The default config comes only with a minimal setup. Check more examples for module setup, styling for image integration.
All the available options are listed below.
…Otter-launcher works well with tui programs and bash pipelines. Some tricktips:
Use your wm's window rules to control window size; make it large enough to prevent a skewed layout.
[[modules]].cmd can be scripted to adjust window sizes. For example:
[[modules]]
description = "pulsemixer for audio control"
prefix = "vol"
cmd = "swaymsg [app_id=otter-launcher] resize set width 600 px height 300 px; pulsemixer; swaymsg [app_id=otter-launcher] resize set width 600 px height 60 px"Some tui utilities that works really well:
To change external editor's window size , call a wrapper script at general.external_editor. Examples of such a wrapper are in contrib.
Using fastfetch in interface.header_cmd works without extra setting. However, add '--pipe false' to fastfetch in overlay.overlay_cmd to prevent its pipe mode from stripping colors.
[interface]
header_cmd = """
fastfetch \
--structure break:colors:break:title:os:shell:kernel:uptime \
--logo-print-remaining false \
--logo-height 8 \
--logo-padding-left 3 \
--sixel $HOME/.config/otter-launcher/images/images_squ/archlinux_chan.jpg
"""
header = " \u001B[33;1m otterly awesome \u001B[0m \u001B[36;1m:\u001B[0;1m "
place_holder = "type & search"
suggestion_mode = "hint"
prefix_color = "\u001B[33m"
description_color = "\u001B[39m"
place_holder_color = "\u001B[30m"
hint_color = "\u001B[90m"Use chafa in header_cmd to render the image.
…Render chafa image at the left, moving the inteface to the right.
…This config renders a prinny using overlay_cmd, and then move the overlay right.
…This custom script use ansi control codes to print texts to the right of a sixel shocked otter.
…If you find the project helpful, you can buy me a coffee through paypal.
暂无开放 Issues,或尚未同步最近议题。