Structured daily/weekly notes - in Obsidian
Tags: obsidian, notetaking, zettelkasten
Published: 2022-11-13 22:57:01

Earlier this week I've been reading a brilliant post [Writing Down What I Do — In Obsidian](https://v5.chriskrycho.com/journal/writing-down-what-i-do-in-obsidian/) from [Chris Krycho](https://v5.chriskrycho.com/index.html) and somehow found myself in a rabbit hole trying to automate some aspects of this approach.

---

## The why

When I'm building a system for myself, I need to make sure that I'm:

- Happy with the idea of how it will look like in the future
- Making it as little chore as possible for myself

Because of these I took the original concept and made it a little bit more "mine".

## The how

The core of the functionality here is revolving around three community plugins: [Templater](https://github.com/SilentVoid13/Templater), [Periodic Notes](https://github.com/liamcain/obsidian-periodic-notes) (which itself requires [Natural Language Dates](https://github.com/argenos/nldates-obsidian)), [Calendar](https://github.com/liamcain/obsidian-calendar-plugin) and [Tasks](https://github.com/obsidian-tasks-group/obsidian-tasks).

### Templater config

- First create a folder in your vault called `/Templater`.
- Then create file `/Templater/Daily.md` with following content:
```
---
date: <% tp.date.now("YYYY-MM-DD", 0, tp.file.title, "YYYY-MM-DD") %>
week: <% tp.date.now("YYYY-[W]W", 0, tp.file.title, "YYYY-MM-DD") %>
year: <% tp.date.now("YYYY", 0, tp.file.title, "YYYY-MM-DD") %>
---

#### Work
- [ ] 💪

#### Meetings
- 🎙

#### Outcomes
1. 🦄
```
- Next create file `/Templater/Weekly.md` with following content:
```
---
week: <% tp.date.now("YYYY-[W]W", 0, tp.file.title, "YYYY-[W]W") %>
year: <% tp.date.now("YYYY", 0, tp.file.title, "YYYY-[W]W") %>
---

## Notes
- 🚂

## History

<%*
Array.from(Array(7).keys()).map((i) => {
  date = tp.date.weekday("YYYY-MM-DD", i, tp.file.title, "YYYY-[W]W");
  tR += `### ${date}\n`;
  tR += `![[Tracking/Daily/${date}#Outcomes]]\n\n`;
});
%>
## Outcomes
1. 🪂
```

- Change following plugin configurations:
  - Templater folder location: `Templater`
  - Trigger Templater on new file creation: `on`

### Periodic notes config

- Create following two folders:
  - `/Tracking/Daily`
  - `/Tracking/Weekly`
- Change following plugin settings:
  - Daily Note Template: `Templater/Daily.md`
  - Daily Notes - Note Folder: `Tracking/Daily`
  - Weekly Note Template: `Templater/Weekly.md`
  - Daily Notes - Note Folder: `Tracking/Weekly`

### Calendar config

- Change following plugin settings:
  - Show week number: `on`

## See it in action

- If you don't have right sidebar open, then press `cmd+p` and select `Toggle right sidebar`.
- Press `cmd+p` and select `Calendar: open view`.
- In the top of the right panel a new calendar icon appeared. When you click it, you should see following:

![Periodic notes calendar widget](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/01pm0dnclsk0coqo8nf9.png)

Now when you click on individual days you should be asked if you want to create new note and if you confirm new note is created with expanded template placeholders:

![Daily note](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/0sq5dpqmofyeqfaj5zzm.png)

And when you click on a week number again a new note will appear with the weekly template fields expanded. Note the "History" section which contains embeds of the outcomes of all daily notes in given week:

![Weekly note](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/l1l0tcdm2aa5jk2bbwsz.png)

## Conclusion

With a little bit of scripting/templating one can create a pretty automated system for organized note taking that provides block embedding of the relevant notes.

---

Photo by <a href="https://unsplash.com/@veloradio?utm_source=unsplash&utm_medium=referral&utm_content=creditCopyText">Raphael Wild</a> on <a href="https://unsplash.com/s/photos/obsidian?utm_source=unsplash&utm_medium=referral&utm_content=creditCopyText">Unsplash</a>