<?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>sinistral.sourcery &#187; Miscellaneous</title>
	<atom:link href="http://tierseven.net/denizens/marc/blog/category/misc/feed/" rel="self" type="application/rss+xml" />
	<link>http://tierseven.net/denizens/marc/blog</link>
	<description>bug bait</description>
	<lastBuildDate>Mon, 28 Dec 2009 08:41:30 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.3</generator>
		<item>
		<title>play it again, sansa</title>
		<link>http://tierseven.net/denizens/marc/blog/2009/12/11/play-it-again-sansa/</link>
		<comments>http://tierseven.net/denizens/marc/blog/2009/12/11/play-it-again-sansa/#comments</comments>
		<pubDate>Fri, 11 Dec 2009 06:08:38 +0000</pubDate>
		<dc:creator>marc</dc:creator>
				<category><![CDATA[Miscellaneous]]></category>

		<guid isPermaLink="false">http://tierseven.net/denizens/marc/blog/?p=149</guid>
		<description><![CDATA[I have recently acquired a Sansa Fuze and (paired with Sennheiser HD 435 headphones) and I&#8217;m very impressed. Its a good looking device with great build quality and &#8211; most importantly &#8211; fantastic sound quality. It&#8217;s so good that I passed up on a 2nd generation iPod Touch (those who know me will know how [...]]]></description>
			<content:encoded><![CDATA[<p>I have recently acquired a <a href="http://www.sandisk.com/products/sansa-music-and-video-players/sandisk-sansa-fuze">Sansa Fuze</a> and (paired with <a href="http://www.sennheiser.com/sennheiser/home_en.nsf/root/wired-headphones-hd435-stereo?Open&amp;path=private_headphones_wired-headphones">Sennheiser HD 435</a> headphones) and I&#8217;m very impressed.  Its a good looking device with great build quality and &#8211; most importantly &#8211; fantastic sound quality.  It&#8217;s so good that I passed up on a 2nd generation iPod Touch (those who know me will know how big a deal that is).</p>
<p>While reports suggest that it supports synching playlists in <a href="http://en.wikipedia.org/wiki/Media_Transfer_Protocol">MTP</a> mode flawlessly, my experience &#8211; as a <a href="http://www.apple.com/mac/">Mac</a> user &#8211; is that <i>creating</i> playlists with the device in <a href="http://en.wikipedia.org/wiki/USB_mass_storage_device_class">MSC</a> mode is tricky.  Although the Fuze supports <a href="http://en.wikipedia.org/wiki/M3u">M3U</a> playlists, it is very picky about the format.  Get it wrong, and the Fuze will refuse (refuze?) to read it, rendering it simply as <code>[Empty]</code>.  Thanks to various people on the Sansa forums I better understand the Fuze&#8217;s quirks and have hacked together the following script to generate playlists:</p>
<pre>
   #!/bin/bash

   # ---------------------------------------------------------------------------- #
   # Sansa Fuze M3U playlist creator                                              #
   #  - run from $SANSA_ROOT/MUSIC                                                #
   # ---------------------------------------------------------------------------- #

   # Don't descend more than 1 level.  In my collection each directory represents
   # an album.  Multi-disc albums - with the individual discs in subdirectories -
   # will have all discs in a single playlist, which is what I want.
   for file in $(find . -maxdepth 1 -type d)
   do
      if [ $file != "." ]
      then
         # Write the playlist in the main album directory
         cd $file
         # Tell find to render the names of the MP3s that it finds using the
         # Windows standard CR-LF line terminator.  (Sansa requirement)
         find . -name \*.mp3 -printf %p\\r\\n | \
         # Convert the '/' file separator to the Windows standard '\' (Sansa
         # requirement).
         sed -e '/\//s//\\/g' | \
         # The Sansa doesn't seem to handle relative paths correctly.  If the
         # filenames in the playlist contain a leading '.\' the device cannot read
         # the playlist and renders it as '[Empty]'.  So we cut those characters
         # from the filename/path produced by 'find'.
         cut -b 3- &gt; $file.m3u
         # Head back for more ...
         cd - &gt; /dev/null
      fi
   done
</pre>
]]></content:encoded>
			<wfw:commentRss>http://tierseven.net/denizens/marc/blog/2009/12/11/play-it-again-sansa/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>technicolor terminal : the Cygwin saga</title>
		<link>http://tierseven.net/denizens/marc/blog/2009/05/29/technicolor-terminal-the-cygwin-saga/</link>
		<comments>http://tierseven.net/denizens/marc/blog/2009/05/29/technicolor-terminal-the-cygwin-saga/#comments</comments>
		<pubDate>Fri, 29 May 2009 11:48:39 +0000</pubDate>
		<dc:creator>marc</dc:creator>
				<category><![CDATA[Cygwin]]></category>
		<category><![CDATA[Miscellaneous]]></category>

		<guid isPermaLink="false">http://tierseven.net/denizens/marc/blog/?p=109</guid>
		<description><![CDATA[Not too long ago I posted a snippet that explained how to enable the 256-color display capabilities of terminals that support it. I&#8217;ve since had a bit of trouble getting this to work in terminals under Cygwin. Applications like Vim understand the capabilities of such a terminal, but less and man would complain: &#160;&#160;&#160;WARNING: terminal [...]]]></description>
			<content:encoded><![CDATA[<p>Not too long ago I <a href="http://tierseven.net/denizens/marc/blog/2009/02/28/technicolour-terminal/">posted a snippet</a> that explained how to enable the 256-color display capabilities of terminals that support it.  I&#8217;ve since had a bit of trouble getting this to work in terminals under <a href="http://www.cygwin.com/" rel="nofollow">Cygwin</a>.  Applications like <a href="http://www.vim.org/">Vim</a> understand the capabilities of such a terminal, but <tt>less</tt> and <tt>man</tt> would complain:</p>
<p><tt>&nbsp;&nbsp;&nbsp;WARNING: terminal is not fully functional</tt></p>
<p>After bit of digging I finally realised that it isn&#8217;t enough to have entries for those terminal types in <tt>/usr/share/terminfo/*/*</tt>.  Some apps expect to find the terminal capabilties described in a termcap file, either <tt>/etc/termcap</tt> or <tt>~/.termcap</tt>.  Fortunately, there is an easy way to export the capabilities described in the terminfo database entries to a termcap file:</p>
<p><tt>&nbsp;&nbsp;&nbsp;$ infocmp -C xterm-256color &gt;&gt; ~/.termcap</tt></p>
<p>If you&#8217;re a <a href="http://www.gnu.org/software/screen/" rel="nofollow">screen</a> user, its worth exporting the entry for <tt>screen-256color</tt> too.  <tt>man infocmp</tt> for more information.</p>
]]></content:encoded>
			<wfw:commentRss>http://tierseven.net/denizens/marc/blog/2009/05/29/technicolor-terminal-the-cygwin-saga/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>unlocking bash</title>
		<link>http://tierseven.net/denizens/marc/blog/2009/05/21/unlocking-bash/</link>
		<comments>http://tierseven.net/denizens/marc/blog/2009/05/21/unlocking-bash/#comments</comments>
		<pubDate>Thu, 21 May 2009 08:48:36 +0000</pubDate>
		<dc:creator>marc</dc:creator>
				<category><![CDATA[Miscellaneous]]></category>

		<guid isPermaLink="false">http://tierseven.net/denizens/marc/blog/?p=97</guid>
		<description><![CDATA[I periodically manage to lock bash with an errant C-S (that&#8217;s &#60;ctrl&#62;+&#60;s&#62; in Emacs-speak). The only way to recover seemed to be kill the shell window (if I was fortunate enough to be in a windowing environment, or in screen). Hannu Nevalainen posted a solution to this problem to the Cygwin mailing list. The problem [...]]]></description>
			<content:encoded><![CDATA[<p>I periodically manage to lock bash with an errant <tt>C-S</tt> (that&#8217;s <tt>&lt;ctrl&gt;+&lt;s&gt;</tt> in Emacs-speak).  The only way to recover seemed to be kill the shell window (if I was fortunate enough to be in a windowing environment, or in <a href="http://www.gnu.org/software/screen/">screen</a>).</p>
<p>Hannu Nevalainen <a href="http://cygwin.com/ml/cygwin/2003-09/msg01149.html">posted a solution</a> to this problem to the Cygwin mailing list.  The problem relates to the use of <tt>C-S</tt> and <tt>C-Q</tt> as the ASCII XOFF and XON flow control characters respectively.  Having hit <tt>C-S</tt>, simply hit <tt>C-Q</tt> to store the bash session.</p>
<p>It seems that my education is lacking some terminal history!</p>
]]></content:encoded>
			<wfw:commentRss>http://tierseven.net/denizens/marc/blog/2009/05/21/unlocking-bash/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>this is a job for Super GRUB!</title>
		<link>http://tierseven.net/denizens/marc/blog/2009/03/26/this-is-a-job-for-super-grub/</link>
		<comments>http://tierseven.net/denizens/marc/blog/2009/03/26/this-is-a-job-for-super-grub/#comments</comments>
		<pubDate>Thu, 26 Mar 2009 10:09:34 +0000</pubDate>
		<dc:creator>marc</dc:creator>
				<category><![CDATA[Miscellaneous]]></category>

		<guid isPermaLink="false">http://tierseven.net/denizens/marc/blog/?p=55</guid>
		<description><![CDATA[I&#8217;ve been evangelizing GNU/Linux where I work, but I was recently forced to revert my Linux/Windows dual-boot to a pure Windows installation and reclaim the Linux partitions for use by Windows. After booting into Windows, I used the Logical Disk Manager to delete the ext3 and swap partitions and create an NTFS partition. All was [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been evangelizing GNU/Linux where I work, but I was recently forced to revert my Linux/Windows dual-boot to a pure Windows installation and reclaim the Linux partitions for use by Windows.</p>
<p>After booting into Windows, I used the Logical Disk Manager to delete the ext3 and swap partitions and create an NTFS partition.  All was well until my next reboot, when I was greeted with:</p>
<p>&nbsp;&nbsp;&nbsp;<code>GRUB Error 17</code></p>
<p>GRUB had been installed to load its configuration files from the Linux partition.  Which I&#8217;d blitzed.  I now needed some way to overwrite GRUB with the Windows bootloader.  Traditionally this is achieved using <code>fdisk</code> by running:</p>
<p>&nbsp;&nbsp;&nbsp;<code>fdisk /mbr</code></p>
<p>With Windows XP, <code>fdisk</code> is available from the Recovery Console; boot from the Windows XP installation CD and follow the prompts until you are given the option to recover an existing Windows installation.  Unfortunately &#8211; due perhaps to some quirk of how GRUB installed itself &#8211; the Windows Setup process blue-screened at the</p>
<p>&nbsp;&nbsp;&nbsp;<code>Setup is starting Windows</code></p>
<p>stage.  I could have booted Linux using a LiveCD and re-installed GRUB with a configuration that simply booted into Windows, but I didn&#8217;t trust GRUB to be able to install its configuration files into an NTFS parition without trashing the partition.  Enter the <a href="http://www.supergrubdisk.org/">Super GRUB Disk</a>.</p>
<p>The <a href="http://www.supergrubdisk.org/">Super GRUB Disk</a> is a nifty boot disk that makes it easer for a novice user to recover a system or experiment with GRUB without inadvertently rendering the system unbootable.  Navigating the basic menus for booting a Windows partition gave me what I needed to get my system up and running.  Using Super GRUB Disk version 0.9766 (baed on GRUB 0.97-os.1) the menu sequence was:</p>
<ol>
<li><code>Choose language &amp; NO HELP</code></li>
<li><code>&lt;Language&gt; Boot Disk</code> (for me: English)</li>
<li><code>Windows</code></li>
<li><code>Boot from 2nd partition (Laptop)</code></li>
</ol>
<p>Being a Dell, the first partition on my system is the Dell Utility partition and the second is the active NTFS partition, so this option was exactly what I needed.  There are also options to boot from other hard disks, and to, of course, install the Windows bootloader (the equivalent of <code>fdisk /mbr</code>).</p>
<p>More information about the various options is available from the <code>Choose language &amp; HELP</code> menu option, and from <a href="http://users.bigpond.net.au/hermanzone/supergrubdiskpage.html">Herman&#8217;s Super Grub Disk Documentation</a>, an excellent reference.</p>
]]></content:encoded>
			<wfw:commentRss>http://tierseven.net/denizens/marc/blog/2009/03/26/this-is-a-job-for-super-grub/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>technicolour terminal</title>
		<link>http://tierseven.net/denizens/marc/blog/2009/02/28/technicolour-terminal/</link>
		<comments>http://tierseven.net/denizens/marc/blog/2009/02/28/technicolour-terminal/#comments</comments>
		<pubDate>Sat, 28 Feb 2009 14:02:12 +0000</pubDate>
		<dc:creator>marc</dc:creator>
				<category><![CDATA[Miscellaneous]]></category>

		<guid isPermaLink="false">http://tierseven.net/denizens/marc/blog/?p=48</guid>
		<description><![CDATA[Ryan McGuire has a nice little post that describes how to enable the 256 colour display capabilities of terminal applications that support it. In short, make sure that an initialisation script like ~/.profile or ~/.bash_profile contains: &#160;&#160;&#160;export TERM=xterm-256color To test, execute M-x list-colors-display in emacs. On MacOS X one will need to install the ncurses [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.enigmacurry.com/">Ryan McGuire</a> has a nice little <a href="http://www.enigmacurry.com/2009/01/20/256-colors-on-the-linux-terminal/">post</a> that describes how to enable the 256 colour display capabilities of terminal applications that support it.  In short, make sure that an initialisation script like <code>~/.profile</code> or <code>~/.bash_profile</code> contains:
<pre>
&nbsp;&nbsp;&nbsp;export TERM=xterm-256color</pre>
<p>To test, execute <code>M-x</code> <code>list-colors-display</code> in emacs.</p>
<p>On MacOS X one will need to install the <i>ncurses</i> package from <a href="http://www.macports.org/">macports</a>.  Unfortunately, the terminal emulator that ships with MacOS X &#8211; Apple&#8217;s Terminal.app &#8211; doesn&#8217;t support 256 colours; use <a href="http://iterm.sourceforge.net/">iTerm.app</a> instead.</p>
]]></content:encoded>
			<wfw:commentRss>http://tierseven.net/denizens/marc/blog/2009/02/28/technicolour-terminal/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>emacs &amp; slime for people like me</title>
		<link>http://tierseven.net/denizens/marc/blog/2008/11/04/emacs-slime-for-people-like-me/</link>
		<comments>http://tierseven.net/denizens/marc/blog/2008/11/04/emacs-slime-for-people-like-me/#comments</comments>
		<pubDate>Tue, 04 Nov 2008 15:37:40 +0000</pubDate>
		<dc:creator>marc</dc:creator>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[Incidentally]]></category>

		<guid isPermaLink="false">http://tierseven.net/denizens/marc/blog/2008/11/04/emacs-slime-for-people-like-me/</guid>
		<description><![CDATA[Peter Christensen has published his &#34;Ultimate n00b SLIME/Emacs cheat sheet&#34; as a Work In Progress. It&#8217;s a very handy quick reference.]]></description>
			<content:encoded><![CDATA[<p>Peter Christensen has published his &quot;<a href="http://www.pchristensen.com/blog/articles/public-beta-open-for-ultimate-n00b-slimeemacs-cheat-sheet/">Ultimate n00b SLIME/Emacs cheat sheet</a>&quot; as a Work In Progress.  It&#8217;s a very handy quick reference.</p>
]]></content:encoded>
			<wfw:commentRss>http://tierseven.net/denizens/marc/blog/2008/11/04/emacs-slime-for-people-like-me/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>bash: clear: command not found</title>
		<link>http://tierseven.net/denizens/marc/blog/2008/05/13/bash-clear-command-not-found/</link>
		<comments>http://tierseven.net/denizens/marc/blog/2008/05/13/bash-clear-command-not-found/#comments</comments>
		<pubDate>Tue, 13 May 2008 00:59:11 +0000</pubDate>
		<dc:creator>marc</dc:creator>
				<category><![CDATA[Cygwin]]></category>
		<category><![CDATA[Miscellaneous]]></category>

		<guid isPermaLink="false">http://tierseven.net/denizens/marc/blog/2008/05/13/bash-clear-command-not-found/</guid>
		<description><![CDATA[A base install of Cygwin does not include the clear command, though the same functionality can be achieved using ^L. The command is part of the ncurses package that may be found in the Libs category. Thanks to Ruben Laguna for his post on the subject. EDIT: This ncurses package now appears in the Utils [...]]]></description>
			<content:encoded><![CDATA[<p>A base install of Cygwin does not include the <code>clear</code> command, though the same functionality can be achieved using <code>^L</code>.  The command is part of the <i>ncurses</i> package that may be found in the <i>Libs</i> category.<br />
Thanks to Ruben Laguna for <a href="http://rubenlaguna.com/wp/2007/09/26/bash-clear-command-not-found/">his post</a> on the subject.</p>
<p>EDIT: This <i>ncurses</i> package now appears in the <i>Utils</i> category.</p>
]]></content:encoded>
			<wfw:commentRss>http://tierseven.net/denizens/marc/blog/2008/05/13/bash-clear-command-not-found/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>cygwin svn: cannot move &#8216;*/tmp/entries&#8217; to &#8216;*/entries&#8217;: permission denied</title>
		<link>http://tierseven.net/denizens/marc/blog/2008/05/13/cygwin-svn-cannot-move-tmpentries-to-entries-permission-denied/</link>
		<comments>http://tierseven.net/denizens/marc/blog/2008/05/13/cygwin-svn-cannot-move-tmpentries-to-entries-permission-denied/#comments</comments>
		<pubDate>Tue, 13 May 2008 00:54:51 +0000</pubDate>
		<dc:creator>marc</dc:creator>
				<category><![CDATA[Cygwin]]></category>
		<category><![CDATA[Miscellaneous]]></category>

		<guid isPermaLink="false">http://tierseven.net/denizens/marc/blog/2008/05/13/cygwin-svn-cannot-more-tmpentries-to-entries-permission-denied/</guid>
		<description><![CDATA[It seems that Cygwin&#8217;s subversion port and Tortoise SVN do not play well together. A default installation of both can result in the following error occuring seemingly at random during long checkout or update operations: Can't move '/cygdrive/c/xxx/trunk/.svn/tmp/entries' to '/cygdrive/c/xxx/trunk/.svn/entries': Permission denied To resolve this, Tortoise SVN&#8217;s icon overlays may need to be disabled entirely [...]]]></description>
			<content:encoded><![CDATA[<p>It seems that Cygwin&#8217;s subversion port and Tortoise SVN do not play well together.  A default installation of both can result in the following error occuring seemingly at random during long checkout or update operations:</p>
<pre>Can't move '/cygdrive/c/xxx/trunk/.svn/tmp/entries'
to '/cygdrive/c/xxx/trunk/.svn/entries':
Permission denied
</pre>
<p>To resolve this, Tortoise SVN&#8217;s icon overlays may need to be disabled entirely as suggested <a href="http://www.cygwin.com/ml/cygwin/2006-09/msg00081.html">here</a>.  While Tortoise SVN <b>doesn&#8217;t</b> have a <i>Disable overlays</i> checkbox, they may be effectly disabled as follows:</p>
<ul>
<li>&lt;SecondaryClickContextMenu&gt; &gt; Tortoise SVN &gt; Settings &gt; Icon Overlays</li>
<li>Ensure the checkout directory is included in the <i>Exclude paths</i> mask (I&#8217;ve taken to using <code>c:*</code> and <code>c:*</code>).</li>
</ul>
<p><a href="http://sourceware.org/ml/cygwin/2007-08/msg00222.html">Others have suggested</a> that it may not be necessary to disable Tortoise SVN&#8217;s overlays entirely, as long as the <i>Show overlays only in explorer</i> tickbox is ticked.  This didn&#8217;t work for me; your kilometerage may vary.</p>
]]></content:encoded>
			<wfw:commentRss>http://tierseven.net/denizens/marc/blog/2008/05/13/cygwin-svn-cannot-move-tmpentries-to-entries-permission-denied/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>NSLog an NSString</title>
		<link>http://tierseven.net/denizens/marc/blog/2008/03/27/nslog-an-nsstring/</link>
		<comments>http://tierseven.net/denizens/marc/blog/2008/03/27/nslog-an-nsstring/#comments</comments>
		<pubDate>Thu, 27 Mar 2008 03:33:02 +0000</pubDate>
		<dc:creator>marc</dc:creator>
				<category><![CDATA[Apple]]></category>
		<category><![CDATA[Code]]></category>
		<category><![CDATA[Incidentally]]></category>

		<guid isPermaLink="false">http://tierseven.net/denizens/marc/blog/2008/03/27/nslog-an-nsstring/</guid>
		<description><![CDATA[NSLog(@"hello, %@", @"world");]]></description>
			<content:encoded><![CDATA[<p><code>NSLog(@"hello, %@", @"world");</code></p>
]]></content:encoded>
			<wfw:commentRss>http://tierseven.net/denizens/marc/blog/2008/03/27/nslog-an-nsstring/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

