Allow [[links]] to folders

I think it is important to remember that the intent of Obsidian is that you have your notes locally and they are in a form that is hoped to be future proof. What we have is a file system hierarchy of plain text notes. Obsidian provides a way to view/edit and add functionality/meaning to the plain text notes.

I think linking to folders Ia a common file system paradigm and I find it missing and should be supported. And the File Explorer should allow me to select a folder when I do a ctl-O. I thinl that the folder notes plugin is the right solution for doing more. In the file system you can create a note with the same name as a folder. The folder notes plugin adds a convention and GUI paradigm as to how to treat these notes.

Lets separate presentation from the storage model.

4 Likes

+1
I need it

1 Like

+1

Came here looking for this.

1 Like

A link to a folder should expose the folder in the Explorer.

A year later, I’d still like to see this happen. A link to a folder could have a slightly different syntax, similar to ![[ for transclusions, but with another character in place of the exclamation point. Then the dropdown menu as you begin typing the name would show only folders, just as [[ and ![[ show only files.

cc: @ryanjamurphy

3 Likes

I’d prefer not to introduce yet more syntax. It’s getting hard to remember these Markdown syntax extensions.

How about if you wanted to autocomplete only on folder names you typed [[ and then / signaling to Obsidian you want only folders.

1 Like

Well, for one thing the use of ! for transclusions creates a precedent for it. And your suggestion would also be adding another character, just after [[ instead of before, and would also be additional syntax to remember. And it would be less precedented than putting a character before the [[.

1 Like

Not quite the same. It’s a character that filters the search. It doesn’t show up in the end text. So someone who reads it wouldn’t have to interpret it.
Now, maybe you do want to make it clear in the link text that you’re pointing to a folder. in that case, you can follow Unix (or URL) convention and add a / to the end of the link text. So now, when you read it, it’s clear the link is to a folder. And note that the / character is the same. Much easier to remember.

1 Like

I’d still find it more elegant if adding ! before [[ indicates a transclusion and adding a different character indicates a folder, and I don’t think it would be hard to remember at all.

I’d also prefer it because the syntax would make it clear up front that it’s a folder link, rather than burying an indicator at the end, where it would look like the easy-to-ignore slash at the end of a URL.

But I think we’ve both made our cases well enough for the devs to choose one of them—or another approach entirely—if they do decide to implement the feature.

1 Like

I am looking for the same functionality. I havent found on as simple as an internal wikilink. However, I did install the Vantage plugin. It allows you to insert into a search based on more complex terms.

In doing do so the only term I entered was the path to a file and it inserted every file in that folder and all sub folders.


Not exactly what you or I were looking for but it gives me a workaround that will do for now.

I believe this fails if the path contains a space.

I think you can escape spaces in paths (\ ), but I haven’t tried it.

@miguelmarcos To deal with spaces in links (to folders or files), read posts in bug report: Space in link to file

It is pain when you have to deal with spaces and other characters in markdown links but it is usually possible to formulate working link. Sometimes at the cost of other properties as discussed in:

1 Like

I also miss this feature in Obsidian.

+1 for this feature.

1 Like

When backlinking folder with ! formatting, the content of the folder should be shown as collection of files in backlink formatting.

Illustration

Shared with Zight

Relevant to feature request:

12 Likes

“links as first class citizens”, this will be really helpful

4 Likes

+1 from me. This’d open up all kinds of potential organizational methods that are currently very clunky to implement.

EDIT:

I imagine the ideal scenario would have two options, just like creating backlinks:

  1. Clicking [[someFolderPath]] The command Files: Reveal current file in navigation does exactly what I would picture this function doing: jumping to the folder’s location & strobing a highlight color.

  2. The alternative, ![[someFolderPath]] could write out a list of all the files and folders in the given folder. Perhaps, if we wanted to get really fancy it could have a few pipe options such as ![[someFolderPath|files]] to display only files, ![[someFolderPath|folders]] to display only the folders, or without a pipe option, which would display both files & folders.

4 Likes

Then I will get a mind map on the tree view :slight_smile : )

2 Likes

I’d love to see this functionality too.

4 Likes

I’m trying to use Obsidian for collaborative notes between myself and work colleagues. I’d like to link to various project folders on dropbox containing drawings, spreadsheets, and various other documents. Files in many of these folders (especially cad drawings) are named according to their revision (i.e. DrawingOfSomedamThing-R2.dwg). When I did a demo today the boss pointed out that I was linking to an out of date file so in stead of R2, I should have been linking to R3.

The solution I’d like to see could be of two forms:

  1. Embed the folder in a note using ![[folder]] so that a list of file links would be displayed, so that clicking on a file would either open it in Obsidian or in an external application.

  2. Show the folder as a link using [[folder]] so that clicking on it would open a file explorer or native file manager to get same access to files.

Also as an aside, it would quite nice if Obsidian would handle file paths and names containing spaces.

IMHO the main use case is to organize external reference materials and make them more easily accessible. Thanks in advance for lisdterning

4 Likes

+1 from me too

1 Like