Artifact Content

Artifact 0b04b1e4ed40e8c909143a74c0c83f10b379bfe29ca9367c32b0456511bf056b:

Pinboard Lua Script for ELinks

Adds the following functionality to ELinks:

Javascript support in ELinks is a bit lacking (it's never worked well for me anyway) so it's not possible to use the Pinboard bookmarklets. Lua support in ELinks is much better, so this script does what the bookmarklets would do, but via lua. Since CSS support in ELinks is also a bit lacking - there's a lot of cruft on the Pinboard mobile sight in ELinks (stuff that's set as display: none, etc) - this script also cleans that up. The Pinboard edit and delete links won't work in ELinks because of javascript again, so this script generates replacement ones: Editing is done by "saving" the bookmark again, since the add page works fine; Deleting is done via the AP, since it is immediately destructive the delete link is only visible on the individual bookmark page, not when browsing through a list of bookmarks.


Source from your ~/.elinks/hooks.lua file with dofile("pinboard.lua") If you want to be able to delete bookmarks on Pinboard then you need to add in your auth_token to a ~/.netrc file in the following format:

	login <Your pinboard login name>
	password <Your pinboard API token>


Developed and tested with ELinks 0.12pre6 and Lua 5.1.4.


Rather than use Lua to hijack the goto_url box, just add the following to ~/.elinks/elinks.conf to search your Pinboard bookmarks using a p prefix:

set = ""