Jump to content

Pinboard Search Workflow


Recommended Posts

Posted (edited)

Hi,

 

I just created an alternative Pinboard workflow that allows searching for pinboard bookmarks within Alfred. It can fetch data asynchronously, so there should not be delays during searches and the matching code has some fuzzy logic. Might come in handy for Pinboard users so I wanted to share.

 

NOTE: It requires Node.JS to be installed. Please get it from http://nodejs.org if you dont have Node.

 

Keywords:

 

pinboardauth username:TOKEN <- set access token (get it from https://pinboard.in/settings/password)

 

pb query <- search for query

pbunread <- items in read later list

pbreload <- force data reload

 

Hold cmd while selecting a bookmark to copy it's url to clipboard.

Hold ctrl while selecting to delete a bookmark from your pinboard.

 

Workflow:

http://d.ekin.io/L6QO

 

Source Code:

https://github.com/eknkc/alfred-pinboard

 

Let me know if it works for you.

Edited by eknkc
Posted (edited)

Posted a little update,

 

Cmd + Click copies URL of a bookmark.

Ctrl + Click deletes a bookmark from pinboard.

A couple of fixes.

Edited by eknkc
Posted

Posted another update with some improvements and additions:

 

- pbunread lists all bookmarks in "read later queue". when you select and open one here, it is automatically marked as read.

- pbreload to force reload data from server.

Posted

OMG, this is just plain AWESOME, thank you a LOT!!!!!!!!!!!!!!!!! :-)

 

Does it need node.js to be installed on my main machine?

Posted

I'm really curious to try this workflow out but the Droplr link is not working for me, I'm getting an Access Denied message.

Posted (edited)

I'm really curious to try this workflow out but the Droplr link is not working for me, I'm getting an Access Denied message.

 

Added a Dropbox link to first post. Droplr's been getting worse lately.

Edited by eknkc
Posted

Added a Dropbox link to first post. Droplr's been getting worse lately.

 

Thanx, working perfectly now!

  • 4 weeks later...
Posted (edited)

So using the pinboardauth command, it didn't seem to be creating the config file. It successfully made the directory, but refused to create or write to the file. If anyone is having this problem, you can just make a config.json file in 

~/Library/Application Support/Alfred 2/Workflow Data/eknkc.pinboard/config.json

With the contents

{
	"token": "user:xxxxxxxxxxxxxxxxxxx"
}

I'm using node v0.8.9. I'm not sure if this is the release that changed the process.nextTick behavior or if your code is only for .9 +. Looking at search.js, it doesn't look like you are doing any error handling for this, which explains why even when the config creation fails, it reports that it's fine in the notification.

 

Sorry, I'd submit a pull request but I'm not familiar with your node style.

 

Update: Added ~ to denote that folder is actually in the user's home path

Edited by fform
Posted

I installed a fresh copy of node.js with Homebrew, using this technique. I also had to create a config.json file manually, as per fform's instructions. Trying to search (i.e. pb foo) results in it defaulting to the Google/Wikipedia/Amazon/etc. fallback search, and it won't load relevant bookmarks.

 

Any idea what could be causing this?

  • 4 weeks later...
  • 2 weeks later...
Posted (edited)

same here 

 

Actually, it works fine... all that I had to do was RTFM:

NOTE: It requires Node.JS to be installed. Please get it from http://nodejs.org if you dont have Node.

 

 

defaults to Google, Wikipedia etc for me as well.

Edited by ediventurin
  • 3 weeks later...
  • 1 month later...
  • 1 month later...
Posted

Having some trouble with this. Was defaulting to Google, Wilipedia, etc as mentioned by others here. Made sure I had a fresh copy of node.js installed, then tried adding a config.json to ~/Library/Application Support/Alfred 2/Workflow Data/eknkc.pinboard/ as has also been suggested. Now it's not defaulting to Google, etc but every time I try to query it prompts me to supply my auth token. I've done that already with pinboardauth but it keeps asking for it.

 

pb.jpg

  • 1 month later...
  • 4 weeks later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...