The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

App::Wubot::Plugin::SafariBookmarks - monitor for new safari bookmarks

VERSION

version 0.3.10

DESCRIPTION

This plugin is just a prototype! Lots more to do here.

Currently this plugin copies the safari bookmarks file:

  ~/Library/Safari/Bookmarks.plist

The file is copied to:

  /tmp/bookmarks.plist

Then the 'plutil' utility is used to convert the plist to XML:

  plutil -convert xml1 /tmp/bookmarks.plist

The file is then read in to a data structure using XML::Simple. The data structure is walked recursively, and all unique URLs in the data structure are returned. Only the URLs are matched; no further parsing of the file has been implemented yet. An attempt is made to fetch the content of the URL using LWP::Simple in order to grab the page title. If the attempt succeeds, the resulting message will have the title set in the 'subject' field, e.g.:

  subject: Slashdot: News for nerds, stuff that matters
  link: http://www.slashdot.org/

If the attempt to fetch the title fails, the subject will simply be set to the URL:

  subject: http://www.slashdot.org/
  link: http://www.slashdot.org/

This plugin uses the wubot caching mechanism, so that messages are only sent when a new URL is found in your bookmarks.

This does also find items added to the reading list in OS X Lion.

SUBROUTINES/METHODS

check( $inputs )

The standard monitor check() method.