Skip to content

fix: use $SHELL -i for exec commands to support aliases and shell functions#242

Merged
avihut merged 1 commit intomasterfrom
fix/execute-user-shell
Feb 20, 2026
Merged

fix: use $SHELL -i for exec commands to support aliases and shell functions#242
avihut merged 1 commit intomasterfrom
fix/execute-user-shell

Conversation

@avihut
Copy link
Owner

@avihut avihut commented Feb 20, 2026

Summary

  • -x/--exec commands were run with sh -c, a non-interactive POSIX shell that doesn't source the user's rc files
  • Changed to use $SHELL -i -c so aliases, shell functions, and other rc-defined shortcuts are available
  • Falls back to sh if $SHELL is not set

Test Plan

  • Run a command with -x using a shell alias (e.g. alias g=git) and verify it works
  • Verify -x still works normally for plain commands without aliases

Fixes #244

…nctions

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@avihut avihut added this to the v1.1.0 milestone Feb 20, 2026
@avihut avihut self-assigned this Feb 20, 2026
@avihut avihut added the fix Bug fix label Feb 20, 2026
@avihut avihut merged commit 35edc3f into master Feb 20, 2026
6 checks passed
@avihut avihut deleted the fix/execute-user-shell branch February 20, 2026 08:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

fix Bug fix

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant