Vimwiki: Creating more than 1 diary entry per day

Created on 17 Aug 2017  路  5Comments  路  Source: vimwiki/vimwiki

I know diaries are usually meant to be separated by day, but I actually used them as a "quick note feature". These notes are often unrelated to one another, and one I get multiple unrelated notes on a day, my entry for that day can get pretty clogged.

I thought it might be good if we could create these quick notes on the fly, maybe it would be good to have an option to allow multiple entries per day or maybe it could be possible to create a new feature called quicknotes. What do you think?

Most helpful comment

You can change diary_link_fmt to also include the time (see here) but that is not supported yet.

All 5 comments

You can change diary_link_fmt to also include the time (see here) but that is not supported yet.

You can change it like this (for example):

let g:vimwiki_list = [{'diary_link_fmt': '%Y-%m-%d_%X'}]

It seems to work fine, but it's not a documented feature (I'm not sure why, I hope we can clarification on that). Let us know if you run into problems.

Thanks! This configuration works well for generating a new diary note every time I press <leader>\w<leader>\w, but when I try to save the buffer via :w I get "Can't open file for writing". I wonder what is wrong.

You are probably on a system that doesn't allow the use of a colon in the filename. Choose a different date format, which by the way isn't portable and depends on your system (see :h strftime and man strftime for Unix systems). You could try %Y-%m-%d_%H_%M_%S.

Thank you very much.

I chose a %Y-%m-%d_%Hh$Mm which gives something like 12h14m48s. This feature is really nice, too bad it isn't portable. It would be nice to have a feature where each note created is counted and then you get something like: 2017-08-19-note_1 then note_2 and so on. But this solves it for me right now, so thanks again!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

ironyman picture ironyman  路  3Comments

imze5z picture imze5z  路  3Comments

lsrdg picture lsrdg  路  5Comments

joaocortes picture joaocortes  路  4Comments

gerardbm picture gerardbm  路  4Comments