<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>n8blog &#187; ScriptExport</title>
	<atom:link href="http://www.n8gray.org/blog/category/projects/scriptexport/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.n8gray.org</link>
	<description>distraction in action</description>
	<lastBuildDate>Thu, 01 Jul 2010 18:21:04 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.6</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>ScriptExport 1.0 is Out</title>
		<link>http://www.n8gray.org/blog/2007/09/19/scriptexport-10-is-out/</link>
		<comments>http://www.n8gray.org/blog/2007/09/19/scriptexport-10-is-out/#comments</comments>
		<pubDate>Thu, 20 Sep 2007 02:37:59 +0000</pubDate>
		<dc:creator>n8</dc:creator>
				<category><![CDATA[OS X]]></category>
		<category><![CDATA[ScriptExport]]></category>

		<guid isPermaLink="false">http://www.n8gray.org/blog/2007/09/19/scriptexport-10-is-out/</guid>
		<description><![CDATA[I finally got around to updating ScriptExport to the official iPhoto &#8216;08 export plugin SDK, added a nice icon and treated this as a good excuse to call it 1.0.  You can get the result in the usual place.  Here&#8217;s the ChangeLog:

      VERY LIKELY BREAKS OLD SCRIPTEXPORT SCRIPTS!
 [...]]]></description>
			<content:encoded><![CDATA[I finally got around to updating ScriptExport to the official iPhoto &#8216;08 export plugin <span class="caps">SDK, </span>added a nice icon and treated this as a good excuse to call it 1.0.  You can get the result in <a href="/code/scriptexport/">the usual place</a>.  Here&#8217;s the ChangeLog:<br />
<ul>
      <li><span class="caps">VERY LIKELY BREAKS OLD SCRIPTEXPORT SCRIPTS</span>!
      <li><span class="caps">BREAKS COMPATIBILITY WITH IPHOTO</span> 6 <span class="caps">AND EARLIER</span>!
      <li>Ported to the official iPhoto &#8216;08 Export Plugin <span class="caps">API.</span>
      <li>The set of metadata available has changed in the iPhoto &#8216;08 <span class="caps">API, </span>and these changes are reflected in ScriptExport.  Summarizing the differences:
            <ul>
                <li> iPImageRanking is renamed iPImageRating
                <li> iPImageCaption is renamed iPImageTitle
                <li> Added iPImageIsPortrait and iPImageIsEdited
                <li> iPImageArchiveDate and iPImageModifiedDate no longer exist
                <li> Albums are handled much differently, so iPAlbumName, iPAlbumComments, and iPAlbumMusicPath no longer exist.  See the documentation above for their replacements.
            </ul>
      <li>The output window Auto-scrolls!  Thanks to Kevin Reid for the example code.
      <li>Fixed a crash when the source file for an image is missing.
</ul><a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save?linkurl=http%3A%2F%2Fwww.n8gray.org%2Fblog%2F2007%2F09%2F19%2Fscriptexport-10-is-out%2F&amp;linkname=ScriptExport%201.0%20is%20Out"><img src="http://www.n8gray.org/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share/Bookmark"/></a>]]></content:encoded>
			<wfw:commentRss>http://www.n8gray.org/blog/2007/09/19/scriptexport-10-is-out/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Goin&#8217; Legit</title>
		<link>http://www.n8gray.org/blog/2007/08/11/goin-legit/</link>
		<comments>http://www.n8gray.org/blog/2007/08/11/goin-legit/#comments</comments>
		<pubDate>Sat, 11 Aug 2007 22:35:00 +0000</pubDate>
		<dc:creator>n8</dc:creator>
				<category><![CDATA[OS X]]></category>
		<category><![CDATA[ScriptExport]]></category>

		<guid isPermaLink="false">http://www.n8gray.org/blog/2007/08/11/goin-legit/</guid>
		<description><![CDATA[When you&#8217;ve got a project like ScriptExport that uses an undocumented plugin API for an Apple product you tend to greet product releases (and even updates) with a bemused sigh.  The iPhoto export API has actually been pretty stable, but it&#8217;s always unsettled me to think of the extra work in store if Apple [...]]]></description>
			<content:encoded><![CDATA[<p>When you&#8217;ve got a project like ScriptExport that uses an undocumented plugin <span class="caps">API </span>for an Apple product you tend to greet product releases (and even updates) with a bemused sigh.  The iPhoto export <span class="caps">API </span>has actually been pretty stable, but it&#8217;s always unsettled me to think of the extra work in store if Apple had decided to change or remove it.  Happily, the chances of that happening have now diminished significantly.  The latest <span class="caps">ADC </span>(Apple Developer Connection) mail contained this paragraph:</p>

<blockquote>Download the iPhoto &#8216;08 Export Plug-in <span class="caps">SDK</span><br /><br />

<span class="caps">ADC</span> Members can download the <a href="https://connect.apple.com/cgi-bin/WebObjects/MemberSite.woa/wa/getSoftware?bundleID=19837">iPhoto 2008 <span class="caps">SDK </span>package</a> which includes documentation and sample code on how to write iPhoto Export plug-ins supported by iPhoto &#8216;08. With step-by-step instructions, you&#8217;ll learn how to make a simple file exporter plug-in using iPhoto&#8217;s Export Plug-in <span class="caps">API.</span> This sample plug-in will allow users to set export image size, quality, and whether or not to embed metadata in the output image.</blockquote>

<p>I haven&#8217;t had a chance to look at the <span class="caps">API </span>yet, but yay!  Hopefully the documentation will clear up some of the more confusing aspects of the <span class="caps">API </span>(like the threading model, for example), and I&#8217;m sure this means good things for its longer-term stability.</p><a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save?linkurl=http%3A%2F%2Fwww.n8gray.org%2Fblog%2F2007%2F08%2F11%2Fgoin-legit%2F&amp;linkname=Goin%26%238217%3B%20Legit"><img src="http://www.n8gray.org/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share/Bookmark"/></a>]]></content:encoded>
			<wfw:commentRss>http://www.n8gray.org/blog/2007/08/11/goin-legit/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Somebody Noticed.</title>
		<link>http://www.n8gray.org/blog/2007/03/16/somebody-noticed/</link>
		<comments>http://www.n8gray.org/blog/2007/03/16/somebody-noticed/#comments</comments>
		<pubDate>Sat, 17 Mar 2007 06:03:47 +0000</pubDate>
		<dc:creator>n8</dc:creator>
				<category><![CDATA[OS X]]></category>
		<category><![CDATA[ScriptExport]]></category>
		<category><![CDATA[Scripting]]></category>

		<guid isPermaLink="false">http://www.n8gray.org/blog/2007/03/16/somebody-noticed/</guid>
		<description><![CDATA[It looks like the MacWeb has finally noticed my baby!  No, not that one.  The ugly one.  And hey, I got a shout out from no less than John Gruber, which probably single-handedly advances me a degree or two closer to Kevin Bacon.

It&#8217;s a nice feeling to see your name in the [...]]]></description>
			<content:encoded><![CDATA[<p>It looks like the <a href="http://www.tuaw.com/2007/03/16/scriptexport-iphoto-plugin-allows-shell-script-manipulation/">MacWeb</a> has finally <a href="http://havegnuwilltravel.apesseekingknowledge.net/2007/03/fun-with-iphoto.html">noticed</a> my baby!  No, not <a href="http://www.n8gray.org/photos/amaya-may-2006/DSC_2040">that one</a>.  <a href="http://www.n8gray.org/code/scriptexport/">The ugly one</a>.  And hey, I got a shout out from no less than <a href="http://daringfireball.net/linked/2007/march#fri-16-scriptexport">John Gruber</a>, which probably single-handedly advances me a degree or two closer to Kevin Bacon.</p>

<p>It&#8217;s a nice feeling to see your name in the blogs you read on a daily basis, even if it happens on a Friday at 10PM <span class="caps">PST </span>and by Monday I&#8217;ll be the only one who remembers this ever happened.  Maybe this is the push I need in order to finally get this thing to v1.0 status.</p><a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save?linkurl=http%3A%2F%2Fwww.n8gray.org%2Fblog%2F2007%2F03%2F16%2Fsomebody-noticed%2F&amp;linkname=Somebody%20Noticed."><img src="http://www.n8gray.org/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share/Bookmark"/></a>]]></content:encoded>
			<wfw:commentRss>http://www.n8gray.org/blog/2007/03/16/somebody-noticed/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>ScriptExport 0.3 is Here</title>
		<link>http://www.n8gray.org/blog/2006/09/08/scriptexport-03-is-here/</link>
		<comments>http://www.n8gray.org/blog/2006/09/08/scriptexport-03-is-here/#comments</comments>
		<pubDate>Fri, 08 Sep 2006 21:48:29 +0000</pubDate>
		<dc:creator>n8</dc:creator>
				<category><![CDATA[ScriptExport]]></category>

		<guid isPermaLink="false">http://www.n8gray.org/blog/2006/09/08/scriptexport-03-is-here/</guid>
		<description><![CDATA[I just put up ScriptExport 0.3.  Get it while it&#8217;s hot!

This version fixes a file-descriptor leak that caused a crash after exporting about 200 items.  The new version has been tested with about 1500 items and all is well.]]></description>
			<content:encoded><![CDATA[<p>I just put up ScriptExport 0.3.  <a href="/code/scriptexport">Get it while it&#8217;s hot!</a></p>

<p>This version fixes a file-descriptor leak that caused a crash after exporting about 200 items.  The new version has been tested with about 1500 items and all is well.</p><a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save?linkurl=http%3A%2F%2Fwww.n8gray.org%2Fblog%2F2006%2F09%2F08%2Fscriptexport-03-is-here%2F&amp;linkname=ScriptExport%200.3%20is%20Here"><img src="http://www.n8gray.org/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share/Bookmark"/></a>]]></content:encoded>
			<wfw:commentRss>http://www.n8gray.org/blog/2006/09/08/scriptexport-03-is-here/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Wordpress?  Why, you&#8217;re soaking in it!</title>
		<link>http://www.n8gray.org/blog/2006/06/27/wordpress-why-youre-soaking-in-it/</link>
		<comments>http://www.n8gray.org/blog/2006/06/27/wordpress-why-youre-soaking-in-it/#comments</comments>
		<pubDate>Tue, 27 Jun 2006 23:28:13 +0000</pubDate>
		<dc:creator>n8</dc:creator>
				<category><![CDATA[Blogging]]></category>
		<category><![CDATA[ScriptExport]]></category>

		<guid isPermaLink="false">http://sandbox.n8gray.org/blog/2006/06/27/wordpress-why-youre-soaking-in-it/</guid>
		<description><![CDATA[In my continuing quest for blogging/content-management bliss I&#8217;ve decided to migrate my website to WordPress.  The migration has been painful, but now it appears to be complete enough that I can take the site live.  You probably aren&#8217;t noticing any dramatic differences, since I ported my oh-so-sexy green and orange theme to WordPress, [...]]]></description>
			<content:encoded><![CDATA[<p>In my continuing quest for blogging/content-management bliss I&#8217;ve decided to migrate my website to <a href="http://www.wordpress.org">WordPress</a>.  The migration has been painful, but now it appears to be complete enough that I can take the site live.  You probably aren&#8217;t noticing any <em>dramatic</em> differences, since I ported my oh-so-sexy green and orange theme to WordPress, but this should make it easier for me to keep things running smoothly on my end, what with the awkward laggy web interface and all.  In the terribly unlikely event that you should find, say, a dead link, please let me know!</p>
<p>I&#8217;m posting this in the ScriptExport category so that those of you who subscribe to just the SE RSS feed will get the message as well.  I&#8217;ve added some redirects so that the old URLs will continue to work, but you should probably switch over to the new ones.  Here are the new links:</p>
<ul>
<li><a href="feed:http://www.n8gray.org/blog/feed/">The main blog feed</a>
<li><a href="feed:http://www.n8gray.org/blog/category/projects/scriptexport/">The ScriptExport AppCast feed</a>
</ul>
<p>BTW, to get an RSS feed of any category, just append &#8220;/feed/&#8221; to the URL you get by clicking on the category in the sidebar.</p>
<a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save?linkurl=http%3A%2F%2Fwww.n8gray.org%2Fblog%2F2006%2F06%2F27%2Fwordpress-why-youre-soaking-in-it%2F&amp;linkname=Wordpress%3F%20%20Why%2C%20you%26%238217%3Bre%20soaking%20in%20it%21"><img src="http://www.n8gray.org/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share/Bookmark"/></a>]]></content:encoded>
			<wfw:commentRss>http://www.n8gray.org/blog/2006/06/27/wordpress-why-youre-soaking-in-it/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>ScriptExport 0.2 Released</title>
		<link>http://www.n8gray.org/blog/2006/06/26/scriptexport-02-released/</link>
		<comments>http://www.n8gray.org/blog/2006/06/26/scriptexport-02-released/#comments</comments>
		<pubDate>Mon, 26 Jun 2006 23:11:05 +0000</pubDate>
		<dc:creator>n8</dc:creator>
				<category><![CDATA[ScriptExport]]></category>

		<guid isPermaLink="false">http://sandbox.n8gray.org/blog/2006/06/26/scriptexport-02-released/</guid>
		<description><![CDATA[I just uploaded ScriptExport 0.2. This version improves compatibility so that SE can be used with iPhoto 5. It also has a new help file that&#8217;s still ugly (unstyled) but not ugly anymore (hideous TextEdit.app HTML). Get it while it&#8217;s hot!
]]></description>
			<content:encoded><![CDATA[<p>I just uploaded <a href="/code/scriptexport">ScriptExport 0.2</a>. This version improves compatibility so that SE can be used with iPhoto 5. It also has a new help file that&#8217;s still ugly (unstyled) but not ugly anymore (hideous TextEdit.app HTML). Get it while it&#8217;s hot!</p>
<a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save?linkurl=http%3A%2F%2Fwww.n8gray.org%2Fblog%2F2006%2F06%2F26%2Fscriptexport-02-released%2F&amp;linkname=ScriptExport%200.2%20Released"><img src="http://www.n8gray.org/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share/Bookmark"/></a>]]></content:encoded>
			<wfw:commentRss>http://www.n8gray.org/blog/2006/06/26/scriptexport-02-released/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>ScriptExport</title>
		<link>http://www.n8gray.org/blog/2006/05/31/scriptexport/</link>
		<comments>http://www.n8gray.org/blog/2006/05/31/scriptexport/#comments</comments>
		<pubDate>Wed, 31 May 2006 12:29:00 +0000</pubDate>
		<dc:creator>n8</dc:creator>
				<category><![CDATA[ScriptExport]]></category>

		<guid isPermaLink="false">http://www.n8gray.org/sandbox/wordpress/?p=46</guid>
		<description><![CDATA[
There are lots of great iPhoto export plugins out there.  There&apos;s FlickrExport,
iPhotoToGallery, Photon, and so on and so on.  Each of these has a specific job
and performs it admirably.  However, there are times when your needs are more 
specialized and you just have to do your own thing.  That&apos;s where ScriptExport [...]]]></description>
			<content:encoded><![CDATA[<p>
There are lots of great iPhoto export plugins out there.  There&apos;s FlickrExport,
iPhotoToGallery, Photon, and so on and so on.  Each of these has a specific job
and performs it admirably.  However, there are times when your needs are more 
specialized and you just have to do your own thing.  That&apos;s where <a href="/code/#ScriptExport">ScriptExport</a> 
comes to the rescue.

<p>ScriptExport allows you to &#8220;export&#8221; your iPhoto pictures and movies by processing them with shell scripts.  You can specify up to three scripts:
<ul>
    <li>Preflight Script:  This is run first
    <li>Per-Item Script:   This is run once per photo or movie selected
    <li>Postflight Script: This is run at the end of the export
</ul>

<p>Any or all of the scripts can be left blank (though if you left all of them blank it 
wouldn&apos;t be very useful).

<p>How is this useful?  Well, in <a href="/blog/2006/04/27#sips">my last post</a> I discussed the need to convert images to sRGB color space when uploading them to be viewed on the web.  I normally use <a href="http://zwily.com/iphoto/">iPhotoToGallery</a> to post my photos, but it doesn&apos;t have the ability to do color space conversions.  Sure, I could have exported the photos as files and run them through an automator action or something, but then I would have lost all the captions I&apos;d added in iPhoto.  I probably could have written something in applescript to process the files, but I deeply abhor applescript.

<p>My solution was to use ScriptExport and a Python script: <a href="/code/files/export2gallery.py">export2gallery.py</a>.  It builds on a mildly-hacked version of <a href="http://garion.tzo.com/python/">gallery-0.2.py</a> (my hacked version is <a href="/code/files/galleryProtocol.py">here</a>).  For each image file, it uses the <i>sips</i> tool to convert the file&apos;s colorspace and dumps the file&apos;s metadata to a sidecar file.  During the postflight stage it uploads all the converted files to my gallery, setting the metadata fields appropriately.  If you&apos;re interested in using ScriptExport with Python then export2gallery should give you a pretty good idea of how to go about it.

<p>If you want to be notified when ScriptExport is updated, subscribe to the <a href="feed://www.n8gray.org/blog/software/ScriptExport/index.rss">ScriptExport RSS &#8220;Appcast&#8221;</a> with your favorite RSS reader.

<p>Finally, I&apos;d like to point out that the source is available, licensed under the LGPL.  I think it should serve as a decent example for anybody trying to build their own iPhoto export plugin.<a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save?linkurl=http%3A%2F%2Fwww.n8gray.org%2Fblog%2F2006%2F05%2F31%2Fscriptexport%2F&amp;linkname=ScriptExport"><img src="http://www.n8gray.org/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share/Bookmark"/></a>]]></content:encoded>
			<wfw:commentRss>http://www.n8gray.org/blog/2006/05/31/scriptexport/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

