2 Commits
Author SHA1 Message Date
Axel Uhl b5218fa611 bash completion: list all options on a bare Tab after the command
Previously the option-name branch was guarded by `$cur == -*`, so a Tab
in option position with an empty current word produced nothing. Drop the
guard: compgen -W filters by $cur anyway, so an empty cur now lists every
option while a partial still narrows. Value completion is unaffected —
those cases return earlier in the function.

Assisted-By: Claude Opus 4.8
2026-08-28 21:03:45 +02:00
Axel Uhl 732be09a2d Add bash completion for merge-upstream-to-downstream.sh
Tab-completes the script's named options and, intelligently, their
values against the git repo containing the CWD:
  - remote-name options complete against 'git remote';
  - remote-branch options (--upstream/downstream/fork-branch) complete
    against the branches OF THE RESOLVED REMOTE, resolving each role to
    a remote with the same precedence the script uses (explicit
    --*-remote on the line > MERGE_U2D_* env var > built-in default);
  - --local-*-branch options complete against local branches.

Install by sourcing from ~/.bashrc or symlinking into a
bash-completion completions dir under the command's basename.

Assisted-By: Claude Opus 4.8
2026-08-28 21:00:24 +02:00