From 837c1473fc90f1eb7f6c742fa5423c85354b78a6 Mon Sep 17 00:00:00 2001 From: Janik von Rotz Date: Fri, 25 Sep 2026 13:56:39 +0200 Subject: [PATCH] feat: add prompt file 8f786f1-add-alias-for-all-commands.md --- 8f786f1-add-alias-for-all-commands.md | 43 +++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) create mode 100644 8f786f1-add-alias-for-all-commands.md diff --git a/8f786f1-add-alias-for-all-commands.md b/8f786f1-add-alias-for-all-commands.md new file mode 100644 index 0000000..22e6b31 --- /dev/null +++ b/8f786f1-add-alias-for-all-commands.md @@ -0,0 +1,43 @@ +--- +title: Add alias for all commands +state: completed +model: infomaniak/moonshotai/Kimi-K2.6 +input_tokens: +--- + +# Run 18 + +Note: @Clanker refers to the "ai agent" (you) who is working on this task. + +@Clanker when working on this task, make sure to: + +- Read context and task section first +- Prepare a list of todos +- Update the todo list while working on the task + +## Context + +Read the `AGENTS.md` and `README.md` to get an understanding of the project. + +## Task + +I already have an alias for the task script called `t`. Now I would like to have task aliases for all commands in `bin`. + +Intstead of running `task commit-with-llm` I want to run `t cwl`. The first letters of the command become the command alias. + +Propose a way to define command aliases. My ideas is appending + +```bash + +cwl() { + commit-with-llm +} +``` + +to `bin/commit-with-llm`. + +## Worklog + +@Clanker Implemented aliases by appending a short function to every script in `bin/` that calls the original command with `"$@"` to pass through arguments. Collision detection ensures each alias is unique: the base alias is built from the first letter of each word, and if two commands collide or would shadow a standard shell command (e.g. `cd`, `ls`, `cp`), the conflicting word is extended with additional letters until the alias is safe and unique. For example `copy-dotenv` → `cod` and `create-dotenv` → `crd`. Shell syntax was verified with `bash -n`. + +@Clanker Set frontmatter state to completed.