Fossil SCM

Applied a fix to fossil-autocomplete.bash posted on the forum, said to avoid adding a space to the end of an autocompleted path: https://fossil-scm.org/forum/forumpost/7ba4a4c495

wyoung 2019-04-17 14:50 UTC trunk
Commit 99ad7fc3f602830a38acdf9911a536a83d3b4ed122f815dcc78e74647425f81a
--- tools/fossil-autocomplete.bash
+++ tools/fossil-autocomplete.bash
@@ -3,13 +3,13 @@
33
function _fossil() {
44
local cur commands
55
cur=${COMP_WORDS[COMP_CWORD]}
66
commands=$(fossil help --all)
77
if [ $COMP_CWORD -eq 1 ] || [ ${COMP_WORDS[1]} = help ]; then
8
- # Command name completion for 1st argument or 2nd if help command.
8
+ # Command name completion for 1st argument or 2nd if help command.
99
COMPREPLY=( $(compgen -W "$commands" $cur) )
1010
else
11
- # File name completion for other arguments.
12
- COMPREPLY=( $(compgen -f $cur) )
11
+ # File name completion for other arguments.
12
+ COMPREPLY=( $(compgen -f $cur{}) )
1313
fi
1414
}
1515
complete -o default -F _fossil fossil f
1616
--- tools/fossil-autocomplete.bash
+++ tools/fossil-autocomplete.bash
@@ -3,13 +3,13 @@
3 function _fossil() {
4 local cur commands
5 cur=${COMP_WORDS[COMP_CWORD]}
6 commands=$(fossil help --all)
7 if [ $COMP_CWORD -eq 1 ] || [ ${COMP_WORDS[1]} = help ]; then
8 # Command name completion for 1st argument or 2nd if help command.
9 COMPREPLY=( $(compgen -W "$commands" $cur) )
10 else
11 # File name completion for other arguments.
12 COMPREPLY=( $(compgen -f $cur) )
13 fi
14 }
15 complete -o default -F _fossil fossil f
16
--- tools/fossil-autocomplete.bash
+++ tools/fossil-autocomplete.bash
@@ -3,13 +3,13 @@
3 function _fossil() {
4 local cur commands
5 cur=${COMP_WORDS[COMP_CWORD]}
6 commands=$(fossil help --all)
7 if [ $COMP_CWORD -eq 1 ] || [ ${COMP_WORDS[1]} = help ]; then
8 # Command name completion for 1st argument or 2nd if help command.
9 COMPREPLY=( $(compgen -W "$commands" $cur) )
10 else
11 # File name completion for other arguments.
12 COMPREPLY=( $(compgen -f $cur{}) )
13 fi
14 }
15 complete -o default -F _fossil fossil f
16

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button