aboutsummaryrefslogtreecommitdiffstats
path: root/bashrc
diff options
context:
space:
mode:
Diffstat (limited to 'bashrc')
-rw-r--r--bashrc17
1 files changed, 17 insertions, 0 deletions
diff --git a/bashrc b/bashrc
index a487cf3..2f0d65b 100644
--- a/bashrc
+++ b/bashrc
@@ -101,6 +101,23 @@ tickle () {
shift
task add wait:$deadline $@
}
+
+# taskwarrior read and review (ensure you have html-xml-utils package installed)
+webpage_title (){
+ curl -s "$@" | hxselect -s '\n' -c 'title' 2>/dev/null
+}
+
+read_and_review (){
+ link="$1"
+ title=$(webpage_title $link)
+ echo $title
+ descr="\"Read and review: $title\""
+ id=$(task add pro:h.reading "$descr" | sed -n 's/Created task \(.*\)./\1/p')
+ task "$id" annotate "$link"
+}
+
+alias rnr=read_and_review
+
# fzf
source /usr/share/fzf/key-bindings.bash
source /usr/share/fzf/completion.bash