Notes (bullet log, etc) from anywhere

In my life, I have recently decided to really keep notes, my days are getting too crazy and complicated. I tried a few tools, but I am a little uncomfortable editing text outside of kakoune. So the solution I came up with was to alias “n” in my shell, and “,n” in kakoune to do that same basic thing, jump into my notes file, insert the current full timesamp and put me in the right place. It is sort of dumb, but also useful.

In my kakrc: map global user n %{: e ~/gdrive/Sync/<ret>ge2o<esc><space>!date +'### %Y.%m.%d@%H:%M:%S'<ret>o<esc>} -docstring "Note a thing"

In my zshrc: alias n="echo \"\" >> ~/gdrive/Sync/ && date +'### %Y.%m.%d@%H:%M:%S' >> ~/gdrive/Sync/ && kak ~/gdrive/Sync/ -e 'execute-keys ge2o<esc><space>'"


EDIT: Improvements I want to make are to never open it twice (named kak instance?) and an OS keybinding to it.