Agree - I've been toying with the idea of using something more... formal, but rolled my own so to speak.
I have a script that runs on login that simply opens two files:
1: this calendar week
2: the last calendar week
... in vim tabs, organized in yearly directories. I live in the terminal anyway.
Making myself see the thing, by opening automatically, was the big part. That let me write more. Keeping the storage simple makes the data accessible and portable.
All of this applies to Obsidian and things too - but I enjoy this kind of tinkering
Glad I hit the mark! I'll provide a copy below. Fair warning: only tested on Linux, not Mac/BSD:
NOTE_DIR="${NOTE_DIR:-${HOME}/notes}"
CURRENT_NOTE=$(date +%Y-week%V)
LAST_WEEK_NAME=$(date -d '7 days ago' +%Y-week%V)
NOTE_PATHS=("$NOTE_DIR/$CURRENT_NOTE" "$NOTE_DIR/$LAST_WEEK_NAME")
EDITOR="${EDITOR:-vim}"
if [[ $EDITOR == *vim* ]]; then
# Run the vim-like editor with tabs
$EDITOR -c ':tab all' "${NOTE_PATHS[@]}"
else
# Run the editor without vim tab arg
$EDITOR "${NOTE_PATHS[@]}"
fi
The bit for '$EDITOR' makes this work for 'vim', but also 'gvim' (vim-X11) and 'neovim'.
The assumption for 'else' is that the other editors simply accept an array of arguments with no other direction required
Edit: I realize now I misspoke - no yearly directories [anymore]; dashed names instead! Apparently I quit that in week 10 of 2023.
IIRC, managing the directories added a few lines I didn't care to keep. I don't look outside of the two week window often :)
Automatic notification. You don't need to push/pull. With the usual sync service or the livesync plugin, you can have the document open in two places and see it get updated immediately.
What is the consequence of the change about not syncing arbitrary plugin files? Will we lose settings synchronization (e.g. template files) for plugins?