# Automatically generate Hooks to a document based on links in it

**URL:** <https://discourse.hookproductivity.com/t/automatically-generate-hooks-to-a-document-based-on-links-in-it/3264>\
**Category:** Discussion & Help\
**Created:** [May 17, 2021, 1:44am UTC](https://discourse.hookproductivity.com/t/automatically-generate-hooks-to-a-document-based-on-links-in-it/3264 "2021-05-17T01:44:49Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![technicalpickles](https://discourse.hookproductivity.com/user_avatar/discourse.hookproductivity.com/technicalpickles/32/1618_2.png) [@technicalpickles](https://discourse.hookproductivity.com/u/technicalpickles)\
**Post date:** [May 17, 2021, 1:44am UTC](https://discourse.hookproductivity.com/t/automatically-generate-hooks-to-a-document-based-on-links-in-it/3264/1 "2021-05-17T01:44:49Z")

</div>

I keep all my notes in Obsidian, and will often use Hook to create Markdown links I can paste into Obsidian as I’m writing them. It’s super handy. I don’t always remember to open Hook to link the URL to my note though.

I always have thought it would be handy to be able to generate links from the links in the document already, without having to explicitly open Hook, and paste the link.

Is such a thing possible already? Are there any examples of dynamically creating links based on a file’s contents? It feels like it should be, but I have a feeling I haven’t searched for the right thing.

---

<div class="post-metadata">

**Author:** ![tonywatkins](https://discourse.hookproductivity.com/user_avatar/discourse.hookproductivity.com/tonywatkins/32/1372_2.png) [@tonywatkins](https://discourse.hookproductivity.com/u/tonywatkins)\
**Post date:** [May 17, 2021, 8:25am UTC](https://discourse.hookproductivity.com/t/automatically-generate-hooks-to-a-document-based-on-links-in-it/3264/2 "2021-05-17T08:25:22Z")

</div>

I do exactly the same thing. There’s just that bit of friction of having to switch back and forth between Bookends (the main source of markdown links in my notes) and Obsidian. If I’m creating several notes relating to one source in Bookends, copying and pasting lots of stuff, I can very easily get the markdown link from the Alfred clipboard history, but it feels much harder to get the Hook link again without going back to the source in Bookends. I think there’s something I’ve not got into my head with the Hook interface here.

---

<div class="post-metadata">

**Author:** ![LucB](https://discourse.hookproductivity.com/user_avatar/discourse.hookproductivity.com/lucb/32/2228_2.png) [@LucB](https://discourse.hookproductivity.com/u/LucB)\
**Post date:** [May 17, 2021, 9:08pm UTC](https://discourse.hookproductivity.com/t/automatically-generate-hooks-to-a-document-based-on-links-in-it/3264/3 "2021-05-17T21:08:24Z")

</div>

Welcome to the Hook Productivity Forum , @technicalpickles. Thanks for the interesting topic.

> [@technicalpickles](#):
>
> I always have thought it would be handy to be able to generate links from the links in the document already, without having to explicitly open Hook, and paste the link.

just to be clear, are you asking to be able to create _hooks_ from the content of the file? More generally, to show in the Hook window a list of all the links that are in the body of a text file? (Not necessarily in the ‘hooked’ section because that is reserved for items you deliberately bidirectionally link.)

If so: not yet, but something we’ve been planning.

---

<div class="post-metadata">

**Author:** ![tonywatkins](https://discourse.hookproductivity.com/user_avatar/discourse.hookproductivity.com/tonywatkins/32/1372_2.png) [@tonywatkins](https://discourse.hookproductivity.com/u/tonywatkins)\
**Post date:** [May 18, 2021, 7:23am UTC](https://discourse.hookproductivity.com/t/automatically-generate-hooks-to-a-document-based-on-links-in-it/3264/4 "2021-05-18T07:23:48Z")

</div>

This is going off the topic of the thread a little, but just to pick up on my last comment: I think my issue with the Hook UI and linking to something that’s already in the list is this: if I invoke Hook on an item I want to link to something in the recent list, I can’t make that link without doing ‘copy link’ and then invoking Hook again (because it closes after cmd + C) then going to the item in the recent list and choosing ‘Hook to copied link’.

---

<div class="post-metadata">

**Author:** ![stevelw](https://discourse.hookproductivity.com/letter_avatar_proxy/v4/letter/s/ea666f/32.png) [@stevelw](https://discourse.hookproductivity.com/u/stevelw)\
**Post date:** [May 18, 2021, 12:34pm UTC](https://discourse.hookproductivity.com/t/automatically-generate-hooks-to-a-document-based-on-links-in-it/3264/5 "2021-05-18T12:34:50Z")

</div>

You can set Hook to keep the window open after copying the recent bookmark. Alternatively, you can also Hook to the link on the clipboard without opening Hook using the keyboard shortcut.

So either:

1. Invoke Hook
2. Copy recent bookmark (window stays open)
3. Hook to copied link.

Or:

1. Invoke Hook
2. Copy recent bookmark
3. Hook to copied link with keyboard shortcut.

---

<div class="post-metadata">

**Author:** ![stevelw](https://discourse.hookproductivity.com/letter_avatar_proxy/v4/letter/s/ea666f/32.png) [@stevelw](https://discourse.hookproductivity.com/u/stevelw)\
**Post date:** [May 18, 2021, 12:37pm UTC](https://discourse.hookproductivity.com/t/automatically-generate-hooks-to-a-document-based-on-links-in-it/3264/6 "2021-05-18T12:37:05Z")

</div>

That said, an option on recent bookmarks to Hook to current context would be useful.

---

<div class="post-metadata">

**Author:** ![tonywatkins](https://discourse.hookproductivity.com/user_avatar/discourse.hookproductivity.com/tonywatkins/32/1372_2.png) [@tonywatkins](https://discourse.hookproductivity.com/u/tonywatkins)\
**Post date:** [May 18, 2021, 4:31pm UTC](https://discourse.hookproductivity.com/t/automatically-generate-hooks-to-a-document-based-on-links-in-it/3264/7 "2021-05-18T16:31:30Z")

</div>

I don’t like Hook staying open after copying the link as I don’t want that most of the time, though it is useful in this context. The problem remains, though (I think), that if something else has gone onto the keyboard after copying the link I need to copy a new link in order to hook it to the recent item.

---

<div class="post-metadata">

**Author:** ![LucB](https://discourse.hookproductivity.com/user_avatar/discourse.hookproductivity.com/lucb/32/2228_2.png) [@LucB](https://discourse.hookproductivity.com/u/LucB)\
**Post date:** [May 18, 2021, 4:38pm UTC](https://discourse.hookproductivity.com/t/automatically-generate-hooks-to-a-document-based-on-links-in-it/3264/8 "2021-05-18T16:38:58Z")

</div>

thank you both. We have significant UI enhancements in the work that will deal with all these issues and more.

---

<div class="post-metadata">

**Author:** ![tonywatkins](https://discourse.hookproductivity.com/user_avatar/discourse.hookproductivity.com/tonywatkins/32/1372_2.png) [@tonywatkins](https://discourse.hookproductivity.com/u/tonywatkins)\
**Post date:** [May 18, 2021, 5:25pm UTC](https://discourse.hookproductivity.com/t/automatically-generate-hooks-to-a-document-based-on-links-in-it/3264/9 "2021-05-18T17:25:38Z")

</div>

Fantastic! Thanks, Luc.

---

<div class="post-metadata">

**Author:** ![technicalpickles](https://discourse.hookproductivity.com/user_avatar/discourse.hookproductivity.com/technicalpickles/32/1618_2.png) [@technicalpickles](https://discourse.hookproductivity.com/u/technicalpickles)\
**Post date:** [May 18, 2021, 5:39pm UTC](https://discourse.hookproductivity.com/t/automatically-generate-hooks-to-a-document-based-on-links-in-it/3264/10 "2021-05-18T17:39:54Z")

</div>

> More generally, to show in the Hook window a list of all the links that are in the body of a text file? (Not necessarily in the ‘hooked’ section because that is reserved for items you deliberately bidirectionally link.)
> 
> If so: not yet, but something we’ve been planning.

That is exactly what I mean. Thanks!

I think I would want them to be bi-directional, so if I’m on a website, I can see the note I link to them on.
