termux-packages/packages/fzf/bin-fzf-tmux.patch

25 lines
988 B
Diff
Raw Normal View History

2020-11-09 00:15:00 +01:00
diff -uNr fzf-0.24.2/bin/fzf-tmux fzf-0.24.2.mod/bin/fzf-tmux
--- fzf-0.24.2/bin/fzf-tmux 2020-11-03 16:32:24.000000000 +0200
+++ fzf-0.24.2.mod/bin/fzf-tmux 2020-11-09 01:13:40.879724746 +0200
2016-01-11 01:51:38 +01:00
@@ -1,4 +1,4 @@
-#!/usr/bin/env bash
+#!/usr/bin/bash
# fzf-tmux: starts fzf in a tmux pane
2020-11-09 00:15:00 +01:00
# usage: fzf-tmux [LAYOUT OPTIONS] [--] [FZF OPTIONS]
2016-01-11 01:51:38 +01:00
2020-11-09 00:15:00 +01:00
@@ -150,10 +150,10 @@
2016-01-11 01:51:38 +01:00
# Clean up named pipes on exit
id=$RANDOM
-argsf="${TMPDIR:-/tmp}/fzf-args-$id"
-fifo1="${TMPDIR:-/tmp}/fzf-fifo1-$id"
-fifo2="${TMPDIR:-/tmp}/fzf-fifo2-$id"
-fifo3="${TMPDIR:-/tmp}/fzf-fifo3-$id"
+argsf="${TMPDIR:-@TERMUX_PREFIX@/tmp}/fzf-args-$id"
+fifo1="${TMPDIR:-@TERMUX_PREFIX@/tmp}/fzf-fifo1-$id"
+fifo2="${TMPDIR:-@TERMUX_PREFIX@/tmp}/fzf-fifo2-$id"
+fifo3="${TMPDIR:-@TERMUX_PREFIX@/tmp}/fzf-fifo3-$id"
2020-11-09 00:15:00 +01:00
tmux_win_opts=( $(tmux show-window-options remain-on-exit \; show-window-options synchronize-panes | sed '/ off/d; s/^/set-window-option /; s/$/ \\;/') )
2016-01-11 01:51:38 +01:00
cleanup() {
2020-11-09 00:15:00 +01:00
\rm -f $argsf $fifo1 $fifo2 $fifo3