alphapapa / pocket-reader.el

Emacs client for Pocket reading list (getpocket.com)
GNU General Public License v3.0
223 stars 12 forks source link

M-x pocket-reader-save-to-pocket #4

Closed unhammer closed 7 years ago

unhammer commented 7 years ago

It'd be nice to be able to save the url at point to pocket (or, if in eww and not at an url, the url of the current page)

alphapapa commented 7 years ago

Hi Kevin,

Unfortunately, as far as I know, this would be a mode-dependent command, as there is no universal way to retrieve a URL across all modes. e.g. if it's an Org buffer you have to use one command (which isn't even built-in to Org), if it's eww you have to use another, if it's w3m you have to use another... I did add a command for that for w3m to the readme yesterday.

So, it would be very handy, but we'd have to account for at least those different modes. Would you be willing to help me work on this, or at least test it?

Thanks.

alphapapa commented 7 years ago

Hi again,

I added a command that works in eww, w3m, and Org, and tries to use thing-at-pt in other modes. Please let me know how it works for you. Thanks.

unhammer commented 7 years ago

Awesome! I'll be testing it out :-)

unhammer commented 7 years ago

Works great in ERC and on [[http://example.com][example.com]] style org links and links from eww, but there are a couple things that I think could be improved: