Skip to content

Enable bash tab completion in containers#217

Merged
Sanne merged 1 commit into
mainfrom
fix-bash-completion
Jun 17, 2026
Merged

Enable bash tab completion in containers#217
Sanne merged 1 commit into
mainfrom
fix-bash-completion

Conversation

@Sanne-ai-bot

Copy link
Copy Markdown
Collaborator

Fixes #213

Changes

  • Add bash-completion package to minimal.yaml
  • Source bash completion script in .bashrc during buildFromScratch

Details

This enables standard bash completions (git subcommands, command flags, etc.) in spawned containers by:

  1. Installing the bash-completion package in the minimal template (inherited by all templates)
  2. Adding a conditional source statement to /home/agentuser/.bashrc that loads /usr/share/bash-completion/bash_completion

The completion script is sourced conditionally (only if the file exists) to maintain robustness.

Testing

After rebuilding templates with these changes, bash completion should work for:

  • Git subcommands (e.g., git fe<Tab>git fetch)
  • Command options and flags
  • Any other completions provided by installed tools

To test:

  1. Rebuild the minimal template: isx build tpl-minimal
  2. Create an instance and shell into it
  3. Try: git fe<Tab> (should complete to git fetch)

Fixes #213 by installing bash-completion package in the minimal
template and sourcing it in agentuser's .bashrc. This enables
standard bash completions (git subcommands, etc.) in spawned
containers.

Changes:
- Add bash-completion to minimal.yaml packages
- Source /usr/share/bash-completion/bash_completion in .bashrc
  during buildFromScratch

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
@Sanne Sanne force-pushed the fix-bash-completion branch from 9beeeff to c18d911 Compare June 17, 2026 11:01
@Sanne Sanne merged commit aee41b8 into main Jun 17, 2026
4 checks passed
@Sanne Sanne deleted the fix-bash-completion branch June 17, 2026 12:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Bash tab completion does not work in containers (e.g. git subcommands)

2 participants