Skip to content

Commit

Permalink
Exclude the bind -x commands from interactive commands
Browse files Browse the repository at this point in the history
  • Loading branch information
akinomyoga committed Feb 16, 2024
1 parent 1f77dc0 commit abbaa02
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions bash-preexec.sh
Original file line number Diff line number Diff line change
Expand Up @@ -222,9 +222,9 @@ __bp_preexec_invoke_exec() {
return
fi

if [[ -n "${COMP_LINE:-}" ]]; then
# We're in the middle of a completer. This obviously can't be
# an interactively issued command.
if [[ -n "${COMP_LINE:-}" || -n "${READLINE_POINT:-}" ]]; then
# We're in the middle of a completer or a keybinding set up by "bind
# -x". This obviously can't be an interactively issued command.
return
fi
if [[ -z "${__bp_preexec_interactive_mode:-}" ]]; then
Expand Down

0 comments on commit abbaa02

Please sign in to comment.