From d9555c33a6148d7cd16467238fea42d257f0ecde Mon Sep 17 00:00:00 2001 From: Jun Zhou Date: Tue, 5 Apr 2016 16:58:50 -0700 Subject: [PATCH] escape pane_current_path --- open.tmux | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/open.tmux b/open.tmux index 1c49585..32e23f1 100755 --- a/open.tmux +++ b/open.tmux @@ -36,14 +36,14 @@ get_editor_from_the_env_var() { command_generator() { local command_string="$1" - echo "xargs -I {} tmux run-shell 'cd #{pane_current_path}; $command_string \"{}\" > /dev/null'" + echo "xargs -I {} tmux run-shell 'cd \"#{pane_current_path}\"; $command_string \"{}\" > /dev/null'" } search_command_generator() { local command_string="$1" local engine="$2" - echo "xargs -I {} tmux run-shell 'cd #{pane_current_path}; $command_string $engine\"{}\" > /dev/null'" + echo "xargs -I {} tmux run-shell 'cd \"#{pane_current_path}\"; $command_string $engine\"{}\" > /dev/null'" } generate_open_command() {