Jump to content

Luzzifus

Member
  • Content Count

    7
  • Joined

  • Last visited

About Luzzifus

  • Rank
    Newbie
  • Birthday 07/06/1982

Profile Information

  • Location
    Germany
  1. I (kinda) fixed the waiting times. What I did was to separate the update (=sync) functions from the search script and run it parallel to the open command. So it runs after every search (but still not more frequently than once every 5 minutes), which makes searching instant. The one case where you could miss a recently added bookmark is if you didn't perform any bookmark search with Alfred since. For this case, I also added an update command to manually sync (which also obeys the 5 minute rule of course). Now I'm not sure how I can share the workflow with you, since it is Davids topic and still mostly his work. May I post it here? Or in a new thread (giving full credit of course)? Or not at all? David, tell me.
  2. I'd really be interested in the concept you have for this. As I see from the Pinboard API, it allows you to fetch bookmarks that were added after a specific date/time, but to identify modified (older) bookmarks you'd still have to fetch all. The change detection meta-field seems to be available only in "all". Or am I missing something?
  3. It does sync the bookmarks from Pinboard before every search, but not more frequently than every 5 minutes. That sync takes about 1-2 seconds for me (~350 bookmarks). I tried to make it refresh in the background but I'm not very good at the alfred interaction part yet.. Would be great if David would take another look at it. For me it's ok to wait a few seconds, but 20 seconds is a bit much, I agree. I don't have that behaviour. But I modded alot of things already (like show recently added bookmarks if no search term is entered), so it could be that I "accidently" fixed it. On the other hand I can't remember seeing this at any time.
  4. That's also bothering me a bit, even though the workflow is really nice. I'm trying to dig through the code but it seems I'm not pro enough for this one..
  5. Hi, I wrote a small modification for this awesome workflow (BIG thanks to David! ) which allows to search for multiple words at once instead of treating all arguments as a single search string. So if you type "pb recipe apple", it returns all your bookmarks containing "recipe" and "apple" in any field. So "recipe" could be a tag and the description could contain "apple". That's basically what Jono was requesting, if I got that right. So to achieve that behaviour, open "search.php" and find the line: $matches = $db->get( 'bookmarks', 'url like "%'.$query.'%" or description like "%'.$query.'%" or extended like "%'.$query.'%" or tag like "%'.$query.'%"' ); Should be around line #35. Remove that line and replace it with: $queries = explode(' ', $query); $where_string = ''; foreach( $queries as $q ): $where_string .= (strlen($where_string) > 0) ? ' and ' : ''; $where_string .= '(url like "%'.$q.'%" or description like "%'.$q.'%" or extended like "%'.$q.'%" or tag like "%'.$q.'%")'; endforeach; $matches = $db->get( 'bookmarks', $where_string ); Save the file and that's it. Hope this helps! ---------------------------------------- **edit: Sometimes the subsequential syncs take some time, maybe I'd rather have the re-syncs manually triggered by its own command ("pbsync" or something like that). Also it would be awesome to have an add-to-pinboard command.
×
×
  • Create New...