aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
author依云 <lilydjwg@gmail.com>2025-03-25 19:31:27 +0800
committerGitHub <noreply@github.com>2025-03-25 11:31:27 +0000
commitcf9efd84cbcc88d43e2e438a20552c796d8ac8e5 (patch)
treeae00bb56ee2aa3089ef2d4567ca65470bc997976
parentfix(1289): clear terminal area if inline (#2600) (diff)
downloadatuin-cf9efd84cbcc88d43e2e438a20552c796d8ac8e5.zip
feat(zsh): re-enable bracketed paste (#2646)
* feat(zsh): re-enable bracketed paste atuin will reset it so after exiting atuin without executing a command, bracketed paste mode is disabled until a command is executed. This breaks e.g. the bracketed-paste-url-magic widget. This change will re-enable it if it's enabled; when it's disabled or unavailable, $zle_bracketed_paste[1] will be empty string. * silent shellcheck
Diffstat (limited to '')
-rw-r--r--crates/atuin/src/shell/atuin.zsh3
1 files changed, 3 insertions, 0 deletions
diff --git a/crates/atuin/src/shell/atuin.zsh b/crates/atuin/src/shell/atuin.zsh
index 7d69d762..be29de27 100644
--- a/crates/atuin/src/shell/atuin.zsh
+++ b/crates/atuin/src/shell/atuin.zsh
@@ -59,6 +59,9 @@ _atuin_search() {
output=$(ATUIN_SHELL_ZSH=t ATUIN_LOG=error ATUIN_QUERY=$BUFFER atuin search $* -i 3>&1 1>&2 2>&3)
zle reset-prompt
+ # re-enable bracketed paste
+ # shellcheck disable=SC2154
+ echo ${zle_bracketed_paste[1]} >/dev/tty
if [[ -n $output ]]; then
RBUFFER=""