Have Obsidian be the handler of .md files / Add ability to use Obsidian as a markdown editor on files outside vault (file association)

I am not sure that’s something all users want

If Obsidian couldn’t include a feature unless all users want it, a lot of existing features would have to come out and a lot of incredibly useful new ones couldn’t be added. (Just imagine the comments in the Linux thread on the Discord if Vim support got removed because not all users want it.) :wink:

1 Like

I use Tangent Notes and I value this feature. But it’s not as simple as you imply. It’s not that only some users might want it but that many users might strongly dislike its impact if it were there. Vaults appearing without being added deliberately; .obsidian files being spread right through the file system; slow performance if it hits a particularly large folder.

As WN says, Obsidian is a vault manager, and many (probably most) users are very careful in how they manage their vaults. This approach would make that harder.

Nit a real objection. Obsidian could create / have a temporary vault to support this. It gets instantiated/used when you open a file outside the vault and closed/cleaned later. Kind of like the sandbox vault.

Further no one has to open in to make Obsidian their default markdown editor.

This is an incredibly important feature and not having it is a total pain.

3 Likes

That would mean default settings, default theme and no plugins. There will be users who hit delays as Obsidian tries to make a massive folder a vault, and a new cleaning process to be added.

The point is that thinking about how to do this is distinctly non-trivial and that the outcomes may be quite different from the ideas being requested. Some of the posts in the thread envisage the editor being separated from vault management and being triggered independently.

1 Like

My thinking is that you wouldn’t make folders outside Obsidian’s real vaults into temporary vaults or anything like that. I agree with you that many users would find that obtrusive, and that it would involve needless import/scanning of many files that have nothing to do with the task of opening one file.

My request is that the module/portion/part/framework of Obsidian that is the Markdown editor be freed to open files outside all the vaults, and that it can be made the default app for .md files. UI settings and extensions could be those of the ‘default’ (or the ‘active’) vault.

Understandably this is not on the agenda of the developers, as they are developing a knowledge-management app based on vaults. On the other hand, those developers who are mainly focusing on the Markdown-editor part of the work might have enough pride in the already-impressive result that they’d be happy with it assuming a greater role on users’ systems.

4 Likes

One last remark – as a workaround, I wrote a script for the Mac. It ensures that all Markdown files are opened in Obsidian. Works by creating symlinks in the vault.

But I’m hoping this hack will prove to be temporary.

7 Likes

I will try this later, but it looks very promising! Thanks for that!

I really hope the devs see this.

“Obsidian: Your PKM AND MARDKOWN-EDITOR!” :smiley:

My request is that the module/portion/part/framework of Obsidian that is the Markdown editor be freed to open files outside all the vaults, and that it can be made the default app for .md files. UI settings and extensions could be those of the ‘default’ (or the ‘active’) vault.

This exactly. :100:

5 Likes

+1. many use cases where I would find value in opening an .md outside the vault

6 Likes

Any text editor or Markdown editor can read .md files.

Barry

Of course that is true. you could even argue you don’t need obsidian since windows notepad can edit all files in your vault, but of course we all love the text folding and hundreds of other capabilities afforded by Obsidian. Thus we all hope to use OBSIDIAN to view/edit external .md files too.

2 Likes

Precisely. I have iA Writer, Typora, Zettlr, Byword, and various text editors, and don’t like writing and editing markdown files in any of them nearly as much as I like using Obsidian.

Thanks for supporting this feature request!

3 Likes

I think the idea of having Obsidian be able to edit text and Markdown files outside an Obsidian vault seems simple. But it seems like that’s not how Obsidian was built from the ground up, so in reality it’s not just removing a limitation.

I’d like to be able to just use Obsidian as a general text/Markdown editor, but I can see the difficulties in enabling this- even if Obsidian has a great editor generally speaking.

This is actually the only reason why I don’t use Obsidian 95% of the time. I don’t need to have a vault for every single isolated .md I use.
Wish I didn’t had to install Typora for something obisidian could technically do better.

5 Likes

Having the possibility to open isolated md files without extensions and settings would be already an improvement, but personally I wouldn’t use it if I cannot also use extensions and settings.
Moreover, separating the editor component from the rest of the app might be complicated for the developers.

However, I think there is a simple solution.

  • have an optional special vault in the computer, say V
  • when opening an md file, say F, search if it is in a vault (there should be an option to specify how many folders upstream (even 0) the search should go)
  • if it is in a vault, open its vault.
  • if it is not in a vault, notify the user, copy F temporarily in vault V, and lock file F to prevent changes from other apps (if possible)
  • Do all the edits; when saving, copy F to original folder.
  • When closing the file, copy it back to its original folder and delete it from vault V.

This approach seems (to me at least) computationally cheap, optional, and simple to implement. It could even be a plugin maybe

Am I missing something? Why couldn’t this process be implemented?

3 Likes

Your idea of establishing temporary vaults would mean setting up plugins and settings anew every time.

Sorry if I was not clear. This special vault should be unique, it should be set only once and would not be deleted after each use.
It would be in some folder specified by the user, and would be used anytime there is the need to work with these files that are not in a vault.

So it would be a special vault that doesn’t do linking?

Exactly, I guess it wouldn’t make sense for this special vault to manage links, because at any time in the vault there would be only the file(s) currently open.
(when the files gets closed, they are saved back to their original location and deleted from this vault.)

It is not acceptable for a contemporary, robust file editor such as Obsidian to not support a feature which simpler programs such as Windows’ Command Prompt, Microsoft Notepad, VIM, Sublime Text, and others, support.

The lack of it is enough to make me strongly consider switching text editors, and be glad I did not entrench my ‘workflow’ in the Obsidian ecosystem.