Sha256: 6ec79551378d24a3086a4fa76a3788c9b83bd606da9cdd1760e5e45557dc904d

Contents?: true

Size: 508 Bytes

Versions: 18

Compression:

Stored size: 508 Bytes

Contents

#!/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))
    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

}


complete -F _timetrap 't'

Version data entries

18 entries across 18 versions & 1 rubygems

Version Path
timetrap-1.15.2 completions/bash/timetrap-autocomplete.bash
timetrap-1.15.1 completions/bash/timetrap-autocomplete.bash
timetrap-1.14.3 completions/bash/timetrap-autocomplete.bash
timetrap-1.15.0 completions/bash/timetrap-autocomplete.bash
timetrap-1.14.2 completions/bash/timetrap-autocomplete.bash
timetrap-1.14.1 completions/bash/timetrap-autocomplete.bash
timetrap-1.14.0 completions/bash/timetrap-autocomplete.bash
timetrap-1.13.0 completions/bash/timetrap-autocomplete.bash
timetrap-1.12.0 completions/bash/timetrap-autocomplete.bash
timetrap-1.11.0 completions/bash/timetrap-autocomplete.bash
timetrap-1.10.0 completions/bash/timetrap-autocomplete.bash
timetrap-1.9.0 completions/bash/timetrap-autocomplete.bash
timetrap-1.8.14 completions/bash/timetrap-autocomplete.bash
timetrap-1.8.13 completions/bash/timetrap-autocomplete.bash
timetrap-1.8.12 completions/bash/timetrap-autocomplete.bash
timetrap-1.8.11 completions/bash/timetrap-autocomplete.bash
timetrap-1.8.10 completions/bash/timetrap-autocomplete.bash
timetrap-1.8.9 completions/bash/timetrap-autocomplete.bash