Add ability to rename an alias and all of its instances

When a page is renamed today, all references to it are updated as you would expect. However, there’s no way to do the same for page aliases. For example, if i have an alias with a typo and want to correct it along with all of its references, i have to add a new corrected alias, manually update each instance of the incorrect alias, and then remove the mispelled/incorrect alias from the page.

If aliases could be renamed along with their references then it would also be fairly straightforward to use this functionality to consolidate consolidate aliases.

Im not sure how the UI would support something like this since the aliases are just page properties. Perhaps it could be in the “…” dropdown menu beside “delete page”. IIRC this was where “rename page” used to be, so maybe it would make sense to have a “Rename Alias” dialog? Or, perhaps a right click on the alias could pop a context menu with the option?

Fully agree, this feature is a must-have to fully start using aliases. I would think the right click could work quite well.
Also in general, the properties of the page could have a pop-up to manage them.

Just contributing my use case here:

I like to keep my filenames tidy (migrated to Logseq from Dendron), and since Logseq uses titles as filenames this requires me use my intended filename as the title of the page. E.g. I would set a title to “android-xml” because I want the filename to be android-xml.md even though a better title would be “Android XML”.

Given the current functionality one solution is to give use alias:: Android XML which means I can link to [[Android XML]], but if I change the alias in the future this would mean that the link [[Android XML]] would go to an empty page.

An alternative would be to be able to set the filename manually with e.g. filename:: android-xml, but that has it’s own set of problems; e.g. what happens if I create a page with the title “android-xml”…

Work around that worked for me:

  1. Remove the alias from the page
  2. Goto the page of the old alias
  3. Rename it to the new alias
  4. Add the new alias to the original page
  5. Re-index
3 Likes