# Comefrom.kak - Filetype-agnostic links that can be referenced everywhere

**URL:** <https://discuss.kakoune.com/t/comefrom-kak-filetype-agnostic-links-that-can-be-referenced-everywhere/2675>\
**Category:** Plugins\
**Tags:** plugins\
**Created:** [April 18, 2025, 11:46am UTC](https://discuss.kakoune.com/t/comefrom-kak-filetype-agnostic-links-that-can-be-referenced-everywhere/2675 "2025-04-18T11:46:34Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![marcc](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/marcc/32/1464_2.png) [@marcc](https://discuss.kakoune.com/u/marcc)\
**Post date:** [April 18, 2025, 11:46am UTC](https://discuss.kakoune.com/t/comefrom-kak-filetype-agnostic-links-that-can-be-referenced-everywhere/2675/1 "2025-04-18T11:46:34Z")

</div>

Hey everyone! I’ve built a new plugin: [comefrom.kak](https://git.sr.ht/~marcc/kakoune-comefrom).

comefrom.kak is a minimal filetype-agnostic note-linking system that leverages Kakoune and `xattr(7)`. Mix and match any filetypes you want for your notes and reference your notes from anywhere!

Here is a screen recording to see how it works: [COMEFROM links - asciinema.org](https://asciinema.org/a/fIaF6PJp82MBOAh06tTzJQwUP)

It’s very much WIP but I’m excited to share it. 🙂

---

<div class="post-metadata">

**Author:** ![Screwtapello](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/screwtapello/32/12_2.png) [@Screwtapello](https://discuss.kakoune.com/u/Screwtapello)\
**Post date:** [June 9, 2025, 7:50am UTC](https://discuss.kakoune.com/t/comefrom-kak-filetype-agnostic-links-that-can-be-referenced-everywhere/2675/2 "2025-06-09T07:50:12Z")

</div>

This looks pretty cool, as way to have documentation links that work across filetypes in the editor.

Using xattr is pretty cool, but as you note not every filesystem supports them. Would it be possible to build the same kind of UI on top of a directory full of symlinks? For example, if I set `$LINKFARM` to the directory where I want to keep my links, then:

- “add a keyword that points to the current buffer” is `ln -s "$kak_buffile" "$LINKFARM/$keyword"`
- “list available keywords” is `ls "$LINKFARM"`
- “look up the file associated with a keyword” is `readlink "$LINKFARM/$keyword"`
- “retarget a keyword at a new file” is `ln -sfn "$kak_buffile" "$LINKFARM/$keyword"`
- “remove a keyword” is `rm "$LINKFARM/$keyword"`

It does mean the keyword→file connection is less self-contained, but I think it also makes it easier to diagnose and investigate, and back up with ordinary tools.

Is there some other reason that makes xattr a better solution?

---

<div class="post-metadata">

**Author:** ![marcc](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/marcc/32/1464_2.png) [@marcc](https://discuss.kakoune.com/u/marcc)\
**Post date:** [June 9, 2025, 10:34am UTC](https://discuss.kakoune.com/t/comefrom-kak-filetype-agnostic-links-that-can-be-referenced-everywhere/2675/3 "2025-06-09T10:34:50Z")

</div>

> [@Screwtapello](#):
>
> Using xattr is pretty cool, but as you note not every filesystem supports them. Would it be possible to build the same kind of UI on top of a directory full of symlinks? For example, if I set `$LINKFARM` to the directory where I want to keep my links, then:

Thanks! I explored symbolic links, but disliked that when you rename a file, the symlink doesn’t follow. So you could create a hard link instead, which could be fine since the idea is to point to documentation.
