fix #66
This commit is contained in:
parent
2494c9c8b5
commit
b257db0bf8
2 changed files with 6 additions and 9 deletions
|
@ -15,21 +15,20 @@ Supported tools:
|
||||||
GNU Bazaar: ""bzr""
|
GNU Bazaar: ""bzr""
|
||||||
|
|
||||||
Default arguments:
|
Default arguments:
|
||||||
""bzr ls -R --versioned -0""
|
'(cd $repo_root && bzr ls -R --versioned | awk \""{printf \\\""$repo_root/\\\"" \\\$0 \\\""\\\n\\\"" }\"")'
|
||||||
" \
|
" \
|
||||||
str fzf_bzr_command "bzr"
|
str fzf_bzr_command "bzr"
|
||||||
|
|
||||||
map global fzf-vcs -docstring "edit file from GNU Bazaar tree" 'b' '<esc>: fzf-bzr<ret>'
|
map global fzf-vcs -docstring "edit file from GNU Bazaar tree" 'b' '<esc>: fzf-bzr<ret>'
|
||||||
|
|
||||||
define-command -hidden fzf-bzr %{ evaluate-commands %sh{
|
define-command -hidden fzf-bzr %{ evaluate-commands %sh{
|
||||||
current_path=$(pwd)
|
|
||||||
repo_root=$(bzr root)
|
repo_root=$(bzr root)
|
||||||
case $kak_opt_fzf_bzr_command in
|
case $kak_opt_fzf_bzr_command in
|
||||||
(bzr) cmd="bzr ls -R --versioned -0" ;;
|
(bzr) cmd="(cd $repo_root && bzr ls -R --versioned | awk \"{printf \\\"$repo_root/\\\" \\\$0 \\\"\\\n\\\" }\")" ;;
|
||||||
(bzr*) cmd=$kak_opt_fzf_bzr_command ;;
|
(bzr*) cmd=$kak_opt_fzf_bzr_command ;;
|
||||||
esac
|
esac
|
||||||
[ ! -z "${kak_client_env_TMUX}" ] && additional_flags="--expect $kak_opt_fzf_vertical_map --expect $kak_opt_fzf_horizontal_map"
|
[ ! -z "${kak_client_env_TMUX}" ] && additional_flags="--expect $kak_opt_fzf_vertical_map --expect $kak_opt_fzf_horizontal_map"
|
||||||
printf "%s\n" "fzf -kak-cmd %{cd $repo_root; edit -existing} -items-cmd %{$cmd} -fzf-args %{-m --expect $kak_opt_fzf_window_map $additional_flags} -post-action %{cd $current_path}"
|
printf "%s\n" "fzf -kak-cmd %{edit -existing} -items-cmd %{$cmd} -fzf-args %{-m --expect $kak_opt_fzf_window_map $additional_flags}"
|
||||||
}}
|
}}
|
||||||
|
|
||||||
§
|
§
|
||||||
|
|
|
@ -15,21 +15,19 @@ Supported tools:
|
||||||
Mercurial SCM: ""hg""
|
Mercurial SCM: ""hg""
|
||||||
|
|
||||||
Default arguments:
|
Default arguments:
|
||||||
""hg locate -f -0 -I .hg locate -f -0 -I .""
|
""hg locate -f""
|
||||||
" \
|
" \
|
||||||
str fzf_hg_command "hg"
|
str fzf_hg_command "hg"
|
||||||
|
|
||||||
map global fzf-vcs -docstring "edit file from mercurial tree" 'h' '<esc>: fzf-hg<ret>'
|
map global fzf-vcs -docstring "edit file from mercurial tree" 'h' '<esc>: fzf-hg<ret>'
|
||||||
|
|
||||||
define-command -hidden fzf-hg %{ evaluate-commands %sh{
|
define-command -hidden fzf-hg %{ evaluate-commands %sh{
|
||||||
current_path=$(pwd)
|
|
||||||
repo_root=$(hg root)
|
|
||||||
case $kak_opt_fzf_hg_command in
|
case $kak_opt_fzf_hg_command in
|
||||||
(hg) cmd="hg locate -f -0 -I .hg locate -f -0 -I ." ;;
|
(hg) cmd="hg locate -f" ;;
|
||||||
(hg*) cmd=$kak_opt_fzf_hg_command ;;
|
(hg*) cmd=$kak_opt_fzf_hg_command ;;
|
||||||
esac
|
esac
|
||||||
[ ! -z "${kak_client_env_TMUX}" ] && additional_flags="--expect $kak_opt_fzf_vertical_map --expect $kak_opt_fzf_horizontal_map"
|
[ ! -z "${kak_client_env_TMUX}" ] && additional_flags="--expect $kak_opt_fzf_vertical_map --expect $kak_opt_fzf_horizontal_map"
|
||||||
printf "%s\n" "fzf -kak-cmd %{cd $repo_root; edit -existing} -items-cmd %{$cmd} -fzf-args %{-m --expect $kak_opt_fzf_window_map $additional_flags} -post-action %{cd $current_path}"
|
printf "%s\n" "fzf -kak-cmd %{edit -existing} -items-cmd %{$cmd} -fzf-args %{-m --expect $kak_opt_fzf_window_map $additional_flags}"
|
||||||
}}
|
}}
|
||||||
|
|
||||||
§
|
§
|
||||||
|
|
Loading…
Reference in a new issue