Repository navigation
feat(shell): add safe opt-in native Tab cycling - #517
Merged
Merged
Conversation
Add a completion-only installer with validated rc hooks, backups, dry-run and feature-only removal. Preserve unrelated configuration and ordinary setup behavior. Keep older Readline Shift+Tab unchanged when no native backward widget exists. Closes #516 Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Satisfy SC2004 in the newer Linux/macOS CI ShellCheck without changing binding or installer behavior. Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Copy native function sources into private fixtures instead of inheriting hosted-runner vendor paths. Exercise rejection of insecure ambient paths without bypassing compinit audits or modifying host permissions. Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Add explicit, native Tab cycling for Bash/Zsh without rerunning the general dotfile installer or silently opting existing users in. A dedicated completion-only command adds separate hooks; unrelated rc content and the existing DevSetup managed block stay intact.
Changes
bash config/dotfiles/install-completion.shopts in both shells. Supports validation-only--dry-run, feature-only--uninstall, unique backups, stable hooks and a checkout-linked helper.DEV_SETUP_COMPLETION=0before the hook preserves prior bindings in a fresh shell. Only Tab/Shift+Tab in insertion keymaps are intentionally overridden after opt-in; modes, vi command maps and unrelated bindings remain unchanged.compinitor altering its audit behavior. Documented framework ordering, effectiveZDOTDIR, login-shell/provider limitations and recovery boundaries.setup.sh, general dotfile installation, startup templates, PowerShell and global configuration are unchanged.Test plan
Passed locally on Linux, Bash 5.1.16 and explicitly unpacked Zsh 5.8.1:
Commands:
The local unpacked Zsh run used the documented test-only
--zsh-initadapter. Final native Linux/macOS completion CI passed 279 lifecycle assertions and 17 runtime scenarios on each OS: Linux Bash 5.2.21/Zsh 5.9, macOS Bash 3.2.57/Zsh 5.9. Both use OS shells without adapters. Native macOS confirms forward-only Bash 3.2 behavior and preserved Shift+Tab. All 12 final PR checks pass: Validate Setup Script, 8/8 and E2E Install Smoke Test, 4/4, including Windows. Final head:fa3769e4fb25c06eaab86d9d85b7bc21629e6620.The first CI style finding was corrected without disabling ShellCheck. Zsh provider tests now copy native function sources into private fixtures instead of depending on insecure ambient runner paths. Both reuse cases prove an injected insecure path is rejected, then initialize over isolated inputs; the dedicated security-abort scenario remains. No compinit audit bypass or host permission changes.
Limits: no physical-terminal/deployed acceptance or multi-file transaction/race guarantee. The maintained runtime harness manually sources isolated rc fixtures; independent Linux recordings additionally verify normal fresh startup. General uninstaller remains separate; completion removal is explicitly documented.
Related
Closes #516
Hygiene checklist
.ymlcontent is ASCII-only; no PowerShell changesdevelop