Default folder for new notes is not applied for references with directories mentioned

Hello,
just found out that the default directory for new notes is applied only for notes with simple names without a hierarchy mentioned (the directory mentioned in the reference name).

Steps to reproduce

  • create new vault with directory my-notes and configured this directory as default location for new notes
  • create new page Untitled via Ctrl+n with content
    reference to a new note: [[topic/TopicRelatedNote]]
    
  • click on newly created reference

Expected result

After clicking on the [[topic/TopicRelatedNote]] (when my-notes is configured as default location for new notes),
the directory topic should be created under the my-notes directory
and file TopicRelatedNote should be created inside the topic directory.
image

Actual result

Directory topic (with file TopicRelatedNote inside that directory)
was created under the root of vault,
not under the my-notes directory, even when my-notes is set as default location for new notes
image

Environment

  • Operating system: Ubuntu 20.04.1
  • Debug info:
SYSTEM INFO:
	Obsidian version: v1.1.9
	Installer version: v1.1.9
	Operating system: #63~20.04.1-Ubuntu SMP Wed Nov 30 13:40:16 UTC 2022 5.15.0-57-generic
	Login status: not logged in
	Insider build toggle: off
	Live preview: on
	Legacy editor: off
	Base theme: dark
	Community theme: none
	Snippets enabled: 0
	Restricted mode: on

RECOMMENDATIONS:
	none


Additional information

If I reference a new note with [[my-notes/topic/TopicRelatedNote]] everything works as expected. But I believe it should not be needed to specify my-notes as it is already defined as default location for new notes.

majky

I think this is the intended behavior. If it behaved the way you’re expecting, you wouldn’t be able to link to folders outside of the default creation folder.

1 Like

Note, too, that some interactions with links depend on your link format setting. See Settings → Files & Links → New link format.

Thanks guys for your reply.

So, if I understand it correctly,
the “default location for new notes” is just default location for new notes for which the path is not specified, not for all the notes.


I use “shortest path when possible” for New link format, as I expect that the obsidian will “forgive me” when I do not specify everytime the whole path from the root to another note, and it will try to find and reference the note regardless.

I was expecting that obsidian browses the whole vault and tries to find the note in the whole vault when I write [[topic/TopicRelatedNote]] or [[TopicRelatedNote]].
In case of [[topic/TopicRelatedNote]], it would want to try to find TopicRelatedNote which is also inside the topic directory. But still somewhere in the whole vault and any other directory may or do not need to be before the topic in the path.
In case [[TopicRelatedNote]] there is no requirement to be included in some specific directory, but still the whole vault would be browsed for the note.
And if there are multiple notes with name TopicRelatedNote, there would be some kind of error.
This, I believe, would support the case when note is out of the default location, too.

But I understand, the specifics and other processes related to modifying and managing these references over time might be more complex than I described here in few minutes.


This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.