aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--fish/completions/todo.sh.fish44
-rw-r--r--fish/functions/todo.sh.fish4
2 files changed, 48 insertions, 0 deletions
diff --git a/fish/completions/todo.sh.fish b/fish/completions/todo.sh.fish
new file mode 100644
index 0000000..c436c37
--- /dev/null
+++ b/fish/completions/todo.sh.fish
@@ -0,0 +1,44 @@
+set -l todo_commands ls list lsa listall lsc lsproj add addm addto append archive deduplicate del do rm pri depri help shorthelp report replace prepend
+# commands
+complete -c todo.sh -f -n "not __fish_seen_subcommand_from $todo_commands" -a ls -d 'List Tasks containing TERM(s) (or not -TERM(s)).'
+complete -c todo.sh -f -n "not __fish_seen_subcommand_from $todo_commands" -a list -d 'List Tasks containing TERM(s) (or not -TERM(s)).'
+complete -c todo.sh -f -n "not __fish_seen_subcommand_from $todo_commands" -a lsa -d 'List all Tasks from todo.txt and done.txt containing TERM (or not -TERM).'
+complete -c todo.sh -f -n "not __fish_seen_subcommand_from $todo_commands" -a listall -d 'List all Tasks from todo.txt and done.txt containing TERM (or not -TERM).'
+complete -c todo.sh -f -n "not __fish_seen_subcommand_from $todo_commands" -a lsc -d 'List contexts (start with an @ sign in todo.txt).'
+complete -c todo.sh -f -n "not __fish_seen_subcommand_from $todo_commands" -a lsproj -d 'List projects (start with a + sign in todo.txt).'
+complete -c todo.sh -f -n "not __fish_seen_subcommand_from $todo_commands" -a add -d 'Adds a Task to your todo.txt file.'
+complete -c todo.sh -f -n "not __fish_seen_subcommand_from $todo_commands" -a addm -d 'Adds one Task per input line to your todo.txt file.'
+complete -c todo.sh -f -n "not __fish_seen_subcommand_from $todo_commands" -a addto -d 'Adds a a line of text to any file located in the todo.txt directory.'
+complete -c todo.sh -f -n "not __fish_seen_subcommand_from $todo_commands" -a append -d 'Adds TEXT TO APPEND to the end of the task on line ITEM#.'
+complete -c todo.sh -f -n "not __fish_seen_subcommand_from $todo_commands" -a archive -d 'Moves all done tasks from todo.txt to done.txt abd removes blank lines.'
+complete -c todo.sh -f -n "not __fish_seen_subcommand_from $todo_commands" -a deduplicate -d 'Removes duplicate lines from todo.txt.'
+complete -c todo.sh -f -n "not __fish_seen_subcommand_from $todo_commands" -a do -d 'Mark Task as DONE.'
+complete -c todo.sh -f -n "not __fish_seen_subcommand_from $todo_commands" -a rm -d 'Remove Task. If TERM is given, remove TERM from Task.'
+complete -c todo.sh -f -n "not __fish_seen_subcommand_from $todo_commands" -a del -d 'Remove Task. If TERM is given, remove TERM from Task.'
+complete -c todo.sh -f -n "not __fish_seen_subcommand_from $todo_commands" -a pri -d 'Add/Replace PRIORITY on Task. PRIORITY must be a letter from A-Z'
+complete -c todo.sh -f -n "not __fish_seen_subcommand_from $todo_commands" -a depri -d 'Remove PRIORITY from Task.'
+complete -c todo.sh -f -n "not __fish_seen_subcommand_from $todo_commands" -a help -d 'Display help about usage, options, built-in and add-on actions, or just the usage help for passed ACTION(s).'
+complete -c todo.sh -f -n "not __fish_seen_subcommand_from $todo_commands" -a shorthelp -d 'List the on-line usage of all built-in and add-on actions.'
+complete -c todo.sh -f -n "not __fish_seen_subcommand_from $todo_commands" -a report -d 'Adds the number of open tasks and done tasks to report.txt.'
+complete -c todo.sh -f -n "not __fish_seen_subcommand_from $todo_commands" -a replace -d 'Replaces task on line ITEM# with UPDATED TODO.'
+complete -c todo.sh -f -n "not __fish_seen_subcommand_from $todo_commands" -a prepend -d 'Adds TEXT TO PREPEND to the beginning of the task on line ITEM#. Quotes optional.'
+
+# options
+complete -c todo.sh -f -a -@ -n "not __fish_seen_subcommand_from -@" -d 'Hide context names in list output. Use twice to show context names (default).'
+complete -c todo.sh -f -a -+ -n "not __fish_seen_subcommand_from -+" -d 'Hide project names in list output. Use twice to show project names (default).'
+complete -c todo.sh -f -a -c -n "not __fish_seen_subcommand_from -c" -d 'Color mode.'
+complete -c todo.sh -f -a -d -n "not __fish_seen_subcommand_from -d" -d 'Use a configuration file other than one of the defaults (e.g. ~/.config/todo/config).'
+complete -c todo.sh -f -a -f -n "not __fish_seen_subcommand_from -f" -d 'Forces actions without confirmation or interactive input.'
+complete -c todo.sh -f -a -h -n "not __fish_seen_subcommand_from -h" -d 'Display a short help message; same as action "shorthelp".'
+complete -c todo.sh -f -a -p -n "not __fish_seen_subcommand_from -p" -d 'Plain mode turns off colors.'
+complete -c todo.sh -f -a -P -n "not __fish_seen_subcommand_from -P" -d 'Hide priority labels in list output. Use twice to show priority labels (default).'
+complete -c todo.sh -f -a -a -n "not __fish_seen_subcommand_from -a" -d 'Do not auto-archive tasks automatically on completion.'
+complete -c todo.sh -f -a -A -n "not __fish_seen_subcommand_from -A" -d 'Auto-archive tasks automatically on completion.'
+complete -c todo.sh -f -a -n -n "not __fish_seen_subcommand_from -n" -d 'Do not preserve line numbers; automatically remove blank lines on task deletion.'
+complete -c todo.sh -f -a -N -n "not __fish_seen_subcommand_from -N" -d 'Preserve line numbers.'
+complete -c todo.sh -f -a -t -n "not __fish_seen_subcommand_from -t" -d 'Prepend the current date to a task automatically when it is added.'
+complete -c todo.sh -f -a -T -n "not __fish_seen_subcommand_from -T" -d 'Do not prepend the current date to a task automatically when it is added.'
+complete -c todo.sh -f -a -v -n "not __fish_seen_subcommand_from -v" -d 'Verbose mode turns on confirmation messages.'
+complete -c todo.sh -f -a -vv -n "not __fish_seen_subcommand_from -vv" -d 'Extra verbose mode prints some debugging information and additional help text.'
+complete -c todo.sh -f -a -V -n "not __fish_seen_subcommand_from -V" -d 'Displays version, license and credits.'
+complete -c todo.sh -f -a -x -n "not __fish_seen_subcommand_from -x" -d 'Disables TODOTXT_FINAL_FILTER.' \ No newline at end of file
diff --git a/fish/functions/todo.sh.fish b/fish/functions/todo.sh.fish
new file mode 100644
index 0000000..89b9fbb
--- /dev/null
+++ b/fish/functions/todo.sh.fish
@@ -0,0 +1,4 @@
+function todo.sh --wraps='~/Documents/Notes/todo/todo.sh' --description 'alias todo.sh=~/Documents/Notes/todo/todo.sh'
+ ~/Documents/Notes/todo/todo.sh $argv
+
+end