Skip to content

Commit

Permalink
fix deactivate with existing PROMPT_COMMAND (#949)
Browse files Browse the repository at this point in the history
  • Loading branch information
jdx authored Oct 20, 2023
1 parent 6aa2382 commit a2fa00d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/shell/bash.rs
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ impl Shell for Bash {

fn deactivate(&self) -> String {
formatdoc! {r#"
PROMPT_COMMAND="${{PROMPT_COMMAND//_rtx_hook;/}}"
PROMPT_COMMAND="${{PROMPT_COMMAND//_rtx_hook/}}"
unset _rtx_hook
unset rtx
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
source: src/shell/bash.rs
expression: replace_path(&deactivate)
---
PROMPT_COMMAND="${PROMPT_COMMAND//_rtx_hook;/}"
PROMPT_COMMAND="${PROMPT_COMMAND//_rtx_hook/}"
unset _rtx_hook
unset rtx
Expand Down

0 comments on commit a2fa00d

Please sign in to comment.