From f7b358495eaeeca9cd82f718516659e981c68e73 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Felix=20F=C3=B6rtsch?= Date: Tue, 10 Mar 2026 14:09:42 +0100 Subject: [PATCH] rename artifact to tmux-cheat-sheet.alfredworkflow, streamline readme Co-Authored-By: Claude Opus 4.6 --- .gitea/workflows/build.yml | 2 +- README.md | 44 ++++++-------------------------------- build/build_workflow.sh | 2 +- 3 files changed, 9 insertions(+), 39 deletions(-) diff --git a/.gitea/workflows/build.yml b/.gitea/workflows/build.yml index f646da3..fcd7571 100644 --- a/.gitea/workflows/build.yml +++ b/.gitea/workflows/build.yml @@ -27,4 +27,4 @@ jobs: with: tag_name: v${{ steps.version.outputs.version }} name: v${{ steps.version.outputs.version }} - files: dist/tmux-command-search.alfredworkflow + files: dist/tmux-cheat-sheet.alfredworkflow diff --git a/README.md b/README.md index 256142c..1b0b4b4 100644 --- a/README.md +++ b/README.md @@ -4,11 +4,7 @@ Quickly look up tmux commands, key bindings, and practical examples directly fro ## Install -1. Build the workflow: - ```bash - bash build/build_workflow.sh - ``` -2. Open `dist/tmux-command-search.alfredworkflow` — Alfred imports it automatically. +Download `tmux-cheat-sheet.alfredworkflow` from the [latest release](https://git.felixfoertsch.de/felixfoertsch/alfred-tmux-cheatsheet/releases/latest) and open it — Alfred imports it automatically. ## Usage @@ -31,41 +27,15 @@ Quickly look up tmux commands, key bindings, and practical examples directly fro Open **Alfred → Workflows → tmux Cheat Sheet → Configure Workflow** to change the prefix key (default: `Ctrl+b`). -## Data Sources +## Development -- **Key bindings** are parsed from your local `man tmux` (always matches your installed version). +**Data sources:** +- **Key bindings** are parsed from your local `man tmux` via `bash scripts/parse_manual.sh`. - **Practical examples** are curated in `data/examples.tsv` — add your own by appending a line: `command-name\tdescription\ttmux command`. - **Tier ordering** controls result priority in `data/tiers.tsv` (1 = essential, 4 = rare). -To regenerate the cheat sheet after a tmux update: +**Regenerate** the cheat sheet after a tmux update: `bash scripts/parse_manual.sh` -```bash -bash scripts/parse_manual.sh -bash build/build_workflow.sh -``` +**Run tests:** `bash tests/test_tmux_search.sh` -## Development - -Run tests: - -```bash -bash tests/test_tmux_search.sh -``` - -## Project Structure - -``` -data/ - examples.tsv Curated practical examples - tiers.tsv Usage frequency ranking (1–4) - tmux_commands.tsv Generated cheat sheet (do not edit) -scripts/ - parse_manual.sh Parses man page + examples into tmux_commands.tsv - tmux_search.sh Alfred script filter (awk-based, <15 ms) -build/ - build_workflow.sh Packages .alfredworkflow -tests/ - test_tmux_search.sh Basic search tests -icon.png Workflow icon -info.plist Alfred workflow definition -``` +**Build locally:** `bash build/build_workflow.sh` diff --git a/build/build_workflow.sh b/build/build_workflow.sh index 0feddb0..4e925a9 100755 --- a/build/build_workflow.sh +++ b/build/build_workflow.sh @@ -4,7 +4,7 @@ set -euo pipefail ROOT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)" OUT_DIR="${ROOT_DIR}/dist" STAGE_DIR="${OUT_DIR}/tmux-workflow" -WORKFLOW_FILE="${OUT_DIR}/tmux-command-search.alfredworkflow" +WORKFLOW_FILE="${OUT_DIR}/tmux-cheat-sheet.alfredworkflow" rm -rf "${STAGE_DIR}" mkdir -p "${STAGE_DIR}" "${OUT_DIR}"