Closed VladimirAlexiev closed 5 months ago
Ok, but let me take the opportunity to mention what's done in ELOT with prefixes. Settings from elot-defaults.el
is loaded, according to the first line of the buffer. Then function update-link-abbrev
(which needs to be renamed as elot-update-link-abbrev
) sets the list of prefixes org-link-abbrev-list-local
according to prefixes-table
. This allows for sparql queries in the buffer to be written without prefix lines.
I think there's a weakness here, in that any prefixes added for a particular query that are not included in the org table of prefixes will not get shortened. This should be tested.
Another weakness is that if you have a file that contains two ontologies or more (under separate headlines), the prefixes may be different between them. This obviously complicates the issue.
And, the prefix list should be updated more frequently than when the file is loaded. It could, e.g., be refreshed with a hook to run when the file is saved.
Hook added so the prefixes in org-link-abbrev-alist-local
are now updated from the org table prefix-table
on save 9665a6f
Sorry, I meant to make this issue in another repo: https://github.com/ljos/sparql-mode/issues/76. Posted question to Github why can't I transfer the issue: https://github.com/orgs/community/discussions/118502