Obsidian Tools v0.3 - CLI App for Mass Markdown Manipulation

Hello dear fellows

I have been using Obsidian as my main information & knowledge management tool for a bit now. I do like it quite much I must say, so I went ahead and created some utility script for my personal use to further ease the maintenance of an increasingly large vault.

The main idea is to be able mass manipulate the whole vault with a few easy-to-use commands. This not only allows me to cleanup hundreds of files within seconds, but also opens amazing new possibilities when it comes to restructuring your knowledgebase.

I the newest Release (v0.3 as of editing this Post, 11.03.21), I added a beta-plugin to declutter a very strongly linked clumb of files. Just as an example if your graph view looks like this:

You could just run the --reduce-noise plugin by passing this as a parameter to the Obsidian Tools executable. This plugins constructs a tree-like graph based on a given starting point. After doing so your markdown files (all of them found in the given vault directory) will be adjusted to represent the newly defined dependency graph.

Or if you would like to improve the usability of each individual file, you might like to do just the opposite by using the --create-references plugin and so forth. You get the idea.

You can find the documentation, source repository and release download here!

This is just an early version but there might be some of you who find it as useful as I do. Be careful when executing commands! I have just done some basic testing and not everything works perfect yet. So, I suggest you perform a data backup of your vault before attempting any manipulations! It would be a shame if you had to manually fix certain issues. I also suggest using a versioning tool like Git to track the changes made.

What do you think?
Feedback? Suggestions?
Always appreciated!

By the way:

I started to look at knowledge and what it represents from an entirely new angle. It is quite a challenge to automate such manners. For that fact I would appreciate a discussion about knowledge itself and the possible ways of representing and structuring it. Also, how one might gain new insights about interdisciplinary connections over many domains.

- Tobias


Hi, this looks useful. It would be even more so if you provided a way to fix ‘dead’ links, perhaps with a regex search/replace (if e.g. the link was dead because a bunch of notes got moved to a different folder).

Hi @cobblepot, thanks for your feedback!

So what you are suggesting is an option to find and fix dead links which are not the exact same path? E.g. if you have a link “My Ideas” and you rename it to “My-Ideas”, now you have a dead link. You then could specify a Regex which would look for files matching the pattern and then replacing the old link with the newly found file?

If you are just talking about the cleaning up process/removal of dead links then I already included this feature in the Cleanup Plugin. You can call it by using the --cleanup argument in the console.

As stated in the documentation:

Cleanup all the .md files in the directory, including sub-directories. Searches for links, validates if the destination file exists and has content, otherwise remove the dead link. Empty files will be deleted in this process.

  • Tobias

Hi @cobblepot. I haven’t forgotten your idea. If you can provide me with a more clear explanation I might be able to add it to a future release.

  • Tobias

Looks very interesting. Any idea how one using macos could install it?

1 Like

mac user here :pleading_face:

Hi @bernardo_v, thanks for your comment! I built the app with a portable .net core 3.0 runtime. I do not own a mac myself, so I need your feedback regarding a working solution. I think theoretically you should too be able to execute dotnet over a terminal/command line interface.

I found this documentation of microsoft regarding dotnet core on mac. Can you tell me if this was any helpful?

Hello :handshake: I hope you are doing well!

I’ve just updated the main post with some additional inputs.
Basically I’ve made some improvements and fixes which are now available as of Release v0.3.

So. What issues have you experienced working with large vaults?

1 Like