From 086e4d66268e2fb1d84129962a33f24fbe0d0e9e Mon Sep 17 00:00:00 2001 From: inkch Date: Wed, 9 Jul 2025 01:16:56 +0900 Subject: [PATCH] docs: add readme --- README.md | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 README.md diff --git a/README.md b/README.md new file mode 100644 index 0000000..ef3bfb6 --- /dev/null +++ b/README.md @@ -0,0 +1,54 @@ +# chot + +**`chot` (ちょっと)** - pronounced /cho-tto/ - is a minimalist launcher for running or editing ephemeral, one-off scripts. + +It lets you keep messy glue code, experimental snippets, or temporary scripts in a central place — and run or edit them with a simple command. + +## Features + +- `chot foo` runs a script called `foo` +- `chot edit foo` opens the script in `$EDITOR` +- `help` and `--help` are supported +- Script directory is configurable and auto-created +- Fish shell completion included + +## Usage + +```sh +chot foo # Runs the script named 'foo' +chot edit foo # Opens 'foo' in your $EDITOR +chot help # Show help +``` + +## Script Directory Resolution + +chot stores and looks for scripts in this order: + +1. `$CHOT_SCRIPT` (if set) +2. `$XDG_DATA_HOME/chot/scripts` (if `$XDG_DATA_HOME` is set) +3. `~/.local/share/chot/scripts` + +If the directory does not exist, it will be created automatically the first time you run or edit a script. + +💡 **Note:** We intentionally delay creating this directory until it's needed — just viewing `--help` shouldn't modify your filesystem. + +## Installation + +```sh +make install +``` + +This will install: + +- `bin/chot` to `~/.local/bin/` +- Fish shell completion to the appropriate directory + +## Uninstallation + +```sh +make uninstall +``` + +## License + +MIT