this repo has no description
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

zsh: daily note function

+22
+22
zsh/zshenv
··· 104 104 echo "Removed task: $selected" 105 105 } 106 106 107 + # Gets today's date in YYYY-MM-DD format 108 + # Open neovim on ~/obsidian/<vault>/Daily/${date}.md 109 + # vault is `brain` if hostname is `vita`, `zapier` if hostname is `asteroid` 110 + function dn() { 111 + local vault 112 + case "$(hostname -s)" in 113 + vita) vault="brain" ;; 114 + asteroid) vault="zapier" ;; 115 + *) 116 + echo "dn: unknown host $(hostname -s)" 117 + return 1 118 + ;; 119 + esac 120 + 121 + local date_str file 122 + date_str=$(date +%Y-%m-%d) 123 + file="$HOME/obsidian/$vault/Daily/${date_str}.md" 124 + 125 + mkdir -p "$(dirname "$file")" 126 + nvim -c Goyo "$file" 127 + } 128 + 107 129 # Accepts a target markdown file and opens it with firefox. 108 130 # 109 131 # Expects the [markdown viewer](https://github.com/simov/markdown-viewer)