-
-
Notifications
You must be signed in to change notification settings - Fork 257
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Enable linking to files via aliases #92
Comments
so implementing aliases is a little bit more involved just because there's lots of ways a file can be opened (eg. clicking link in preview, using lookup, going to definition, another extension) i've put together a prototype that will check if a note is an alias and if so, open up the note its pointing to. currently there's a slight flicker because we actually open and then close the original document before opening the alias: the alias is defined in a schema file with an |
Thanks for the fast reply! It seems workable, but I would not call it perfect.. (yeah, yeah, beggars choosers) Ideally, it would allow me to either write the alias directly to the target (death.md), or allow me to manage all my aliases in a central file. As I understand your implementation, I would have to create an alias file for each alias (and who says that we stop at one alias?). Also, I am concerned about the flickering. It kinda works for me, but if it gets added to the master, outsiders* might take it as a a bug. I am also a bit worried about unintended results the opening and closing might have - for example, the creation might trigger some code cleanup or beautifer (Beautifer, Prettier) and misbehave. Now that I think about it, I run like 30 something extensions. I can't be sure if this won't trigger some erratic behaviour. If this is too much trouble, I am completely fine with you shelving the issue until more people become aware. *people that do not know about this this issue/conversation |
yeah, definitely not perfect. i'm going to do some thinking on this. i do want to support the ability for aliases in the future but also need to consider the ux. i'm hesitant to make i think aliases will be defined in either one of two places:
leaning towards putting aliases inside |
If I navigate the link [[final journey]] it leads me to death.md where I can easily edit the alias again. |
ah, i see. that would work. I was thinking of having a file called
what you are saying is much more sensible 😅 |
Great, and sorry for the confusion. Explaining things in text is hard... But I think we got there. The whole point of this is to not have a file called |
This may be possible with symlinks on UNIX based operating systems (Mac OS X and linux) |
Symlinks can work - only issue is that it won't be portable across computers (eg. if you commit to git/dropbox, you will lose the symlink) |
As I'm sure you're aware, this is available in Obsidian, and the UX works very nicely. It's the one feature that is holding me back from using Dendron. It's good to hear that you're thinking it through thoroughly. Symlinks would be a bad solution for me, for the reason you say – it will break across machines and in git repos. Looking forward to seeing the Dendron solution. |
According to this stackoverflow answer, git can handle symlinks correctly. But implementing a symlink solution will require some special directory, under which real files should be kept (to prevent issues with broken symlinks). And, perhaps some mechanism to detect files that should be symlinks, but are not (e.g. because workspace was backed up to cloud storage that doesn't support symlinks). |
Thanks for the update. The way we're planning on handling symlinks is the same way Obsidian is doing it. Just haven't been able to find bandwidth to work on this feature yet. Will highlight this in our dev channel to see if someone wants to jump on this. |
Hmmm... i guess not... 1 year gone since last update and still no solution. |
Hmmm... again nearly a year gone and still nothing happened.... |
Dendron in no longer in active development, see here: |
I try to replace Quoll with Dendron/Roam.
The single most featue I am missing is being able to create aliases for files, which I then can link to.
For example I write "is [[death]] just another journey?" and it points me to death.md.
Now in a different document I exclaim: "and so he went on his [[final journey]]. I don't want this to point to final journey.md, I also want it to link to death.md.
Furthermore, I don't want to write it as [[final journey|death]]:
From a technical perspective, I don't imagine it to be difficult. AFAIK, Dendron already uses YAML-Frontmatter, so adding an "alias"-field there and updating the link database should to the trick - not that I actually know what I am talking about :)
The text was updated successfully, but these errors were encountered: