diff --git a/bootstrap b/bootstrap index 1a8ff4f..b4bde6e 100755 --- a/bootstrap +++ b/bootstrap @@ -34,6 +34,8 @@ h "$dotfilesPath/tmux.conf" "$HOME/.tmux.conf" mkd "$HOME/bin/" find "$dotfilesPath/bin" -type f -exec ln -sf {} "$HOME/bin/" \; +create_links_in_dir_recursively "todo.actions.d" ".todo.actions.d" + create_links_in_dir_recursively "config" ".config" h "$dotfilesPath/config/alacritty.yml" "$HOME/.config/alacritty.yml" h "$dotfilesPath/config/electron-flags.conf" "$HOME/.config/electron-flags.conf" diff --git a/config/todo/actions/@ b/config/todo/actions/@ new file mode 100755 index 0000000..9aa2336 --- /dev/null +++ b/config/todo/actions/@ @@ -0,0 +1,16 @@ +#!/usr/bin/env bash +action=$1 +shift + +CONTEXTS=$(grep -o '[^ ]*@[^ ]\+' "$TODO_FILE" | grep '^@' | sort -u | sed 's/^@//g' ) +for context in $CONTEXTS ; do + if [[ $context == "someday" ]]; then + continue + fi + + CONTEXT_LIST=$(_list "$TODO_FILE" "@$context\b" "$@" | sed 's/\ *@[a-zA-Z0-9._\-]*\ */ /g') + if [[ -n "${CONTEXT_LIST}" ]]; then + echo -e "--@${context}" + echo "${CONTEXT_LIST}" | eval $TODOTXT_FINAL_FILTER + fi +done diff --git a/config/todo/config b/config/todo/config new file mode 100644 index 0000000..c7e3a78 --- /dev/null +++ b/config/todo/config @@ -0,0 +1,20 @@ +# vim: ft=bash +# reference: /etc/todo/config + +export TODO_ACTIONS_DIR="$HOME/.dotfiles/config/todo/actions" + +export TODO_DIR=~/org/ +export TODO_FILE="$TODO_DIR/todo.txt" +export DONE_FILE="$TODO_DIR/done.txt" +export REPORT_FILE="$TODO_DIR/.report.txt" + +export PRI_A=$YELLOW +export PRI_B=$PURPLE +export PRI_C=$LIGHT_BLUE + +export COLOR_PROJECT=$GREEN +export COLOR_CONTEXT=$CYAN +export COLOR_DATE=$BLUE +export COLOR_NUMBER=$CYAN + +export COLOR_META=$BLUE