initial commit

This commit is contained in:
Daniel Fichtinger 2025-07-17 22:42:32 -04:00
commit 3d676babd5
3 changed files with 168 additions and 0 deletions

37
README.md Normal file
View file

@ -0,0 +1,37 @@
# foot scripts
[foot]: https://codeberg.org/dnkl/foot
[`wtype`]: https://github.com/atx/wtype
This repository contains scripts for [foot].
## `foot-command`
This script implements a command palette for Foot. It allows you to
interactively pick a command defined in your `foot.ini` keybindings, and
simulate its corresponding keypress with [`wtype`]. Here's how it works:
1. Parses keybindings from the `[key-bindings]` section of `foot.ini`.
2. Pipes the list of commands to a picker and waits for a selection.
3. Sends the mapped keypress to to the focused window using `wtype`.
### Dependencies
- [`wtype`].
- A dmenu-compatible picker (e.g. `fuzzel`).
### Usage
```sh
foot-command.py [-c PATH_TO_CONFIG] [-p PICKER_COMMAND]
```
I recommend binding this to a key in your window manager. You need to invoke the
command when Foot is the focused window.
### Options
- `-c`, `--config`: Path to your `foot.ini` file. Defaults to
`$HOME/.config/foot/foot.ini`.
- `-p`, `--picker`: Picker to use (must support `dmenu` style input). Defaults
to `fuzzel --dmenu --placeholder=Select a command:`.