completions/bash/timetrap-autocomplete.bash in timetrap-1.15.2 vs completions/bash/timetrap-autocomplete.bash in timetrap-1.15.4
- old
+ new
@@ -1,11 +1,12 @@
#!/bin/bash
_timetrap ()
{
cur="${COMP_WORDS[COMP_CWORD]}"
cmd="${COMP_WORDS[1]}"
+
if [[ ( $cmd = s* || $cmd = d* ) && "$COMP_CWORD" = 2 ]]; then
- COMPREPLY=($(compgen -W "$(echo "select distinct sheet from entries where sheet not like '\_%';" | sqlite3 ~/.timetrap.db)" $cur))
+ COMPREPLY=($(compgen -W "$(echo "select distinct sheet from entries where sheet not like '\_%';" | t b)" $cur))
return
elif [[ "$COMP_CWORD" = 1 ]]; then
CMDS="archive backend configure display edit in kill list now out resume sheet week month"
COMPREPLY=($(compgen -W "$CMDS" $cur))
fi