From c45bdb58ae8265857b990931e5584ee88beb6888 Mon Sep 17 00:00:00 2001 From: Siraaj Khandkar Date: Wed, 3 Apr 2019 07:46:03 -0400 Subject: [PATCH] Add work log template functions --- lib/login_functions.sh | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/lib/login_functions.sh b/lib/login_functions.sh index ba0940a..add0cd0 100644 --- a/lib/login_functions.sh +++ b/lib/login_functions.sh @@ -64,6 +64,36 @@ gh_clone_org() { gh_clone 'orgs' "$1" } +work_log_template() { +cat << EOF +$(date +%F) +========== + +Morning report +-------------- + +### Yesterday + +### Today + +### Blockers + +Day's notes +----------- +EOF +} + +work_log() { + mkdir -p "$DIR_WORK_LOG" + file_work_log_today="${DIR_WORK_LOG}/$(date +%F).md" + if [ ! -f "$file_work_log_today" ] + then + work_log_template > "$file_work_log_today" + fi + vim "$file_work_log_today" + +} + weather() { curl "http://wttr.in/$WEATHER_LOCATION" } -- 2.20.1