<?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>Stefan Sobek Blog &#187; Apple</title>
	<atom:link href="http://www.sobek.info/blog/category/apple/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.sobek.info/blog</link>
	<description>Writing about IT, Software Engineering, sports and other stuff</description>
	<lastBuildDate>Mon, 24 Jan 2011 12:50:08 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Linux, Unix, Mac &#8211; Loop filenames with spaces</title>
		<link>http://www.sobek.info/blog/2010/05/10/linux-unix-mac-loop-filenames-with-spaces/</link>
		<comments>http://www.sobek.info/blog/2010/05/10/linux-unix-mac-loop-filenames-with-spaces/#comments</comments>
		<pubDate>Mon, 10 May 2010 14:23:23 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Apple]]></category>
		<category><![CDATA[Bash]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[loop filenames]]></category>
		<category><![CDATA[shellscript]]></category>
		<category><![CDATA[spaces in linux filenames]]></category>

		<guid isPermaLink="false">http://www.sobek.info/blog/?p=272</guid>
		<description><![CDATA[Situation 
You want to operate on a linux, unix or mac system some files in a bash script and do some file operations like modifying the text content or moving the files to another location depending on the filename, content or another mathinc pattern. 
Problem 
Wondered why you have problems with windows files in a [...]]]></description>
			<content:encoded><![CDATA[<h5>Situation </h5>
<p>You want to operate on a linux, unix or mac system some files in a bash script and do some file operations like modifying the text content or moving the files to another location depending on the filename, content or another mathinc pattern. </p>
<h5>Problem </h5>
<p>Wondered why you have problems with windows files in a network when looping over them? Linux takes whitespaces in file name as line separator so that echoing the file will cause a separate line and so you cannot operate on this file. </p>
<h5>Solution </h5>
<p>I guess it is called <strong>Instruction Field Separator</strong> or something. You have to set this only to line break and not to whitespaces. First save the old variable content, then set the new content so that the bash do not takes whitespaces as line separators</p>

<div class="wp_codebox_msgheader"><span class="right"><sup><a href="http://www.ericbess.com/ericblog/2008/03/03/wp-codebox/#examples" target="_blank" title="WP-CodeBox HowTo?"><span style="color: #99cc00">?</span></a></sup></span><span class="left"><a href="javascript:;" onclick="javascript:showCodeTxt('p272code2'); return false;">View Code</a> BASH</span><div class="codebox_clear"></div></div><div class="wp_codebox"><table width="100%" ><tr id="p2722"><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
</pre></td><td class="code" id="p272code2"><pre class="bash" style="font-family:monospace;"><span style="color: #007800;">OLDIFS</span>=<span style="color: #007800;">$IFS</span>
<span style="color: #007800;">IFS</span>=$<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #660033;">-en</span> <span style="color: #ff0000;">&quot;<span style="color: #000099; font-weight: bold;">\n</span>\b&quot;</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">for</span> FILE <span style="color: #000000; font-weight: bold;">in</span> $<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #c20cb9; font-weight: bold;">find</span> . <span style="color: #660033;">-name</span> <span style="color: #ff0000;">'*.txt)
do
   echo $FILE
done
&nbsp;
$IFS = $OLDIFS</span></pre></td></tr></table></div>

]]></content:encoded>
			<wfw:commentRss>http://www.sobek.info/blog/2010/05/10/linux-unix-mac-loop-filenames-with-spaces/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Drucken an der Apple Time Capsule</title>
		<link>http://www.sobek.info/blog/2008/05/25/drucken-an-der-apple-time-capsule/</link>
		<comments>http://www.sobek.info/blog/2008/05/25/drucken-an-der-apple-time-capsule/#comments</comments>
		<pubDate>Sun, 25 May 2008 10:57:45 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Apple]]></category>
		<category><![CDATA[Drucken]]></category>
		<category><![CDATA[ML2010]]></category>
		<category><![CDATA[Samsung]]></category>
		<category><![CDATA[Time Capsule]]></category>

		<guid isPermaLink="false">http://www.sobek.info/blog/2008/05/25/drucken-an-der-apple-time-capsule/</guid>
		<description><![CDATA[Die Time Capsule von Apple ist wohl eines der besten Gerätschaften, die Apple in letzter Zeit herausgebracht hat. Mein MacBook sichert jeden Tag, jede Stunde automatisch und auf der 1 TB großen Festplatte ist auch noch genug Platz um Bilder oder Musik unterzubringen.
Es gibt jedoch Probleme mit einigen Druckern, welche über USB an die Time [...]]]></description>
			<content:encoded><![CDATA[<p>Die Time Capsule von Apple ist wohl eines der besten Gerätschaften, die Apple in letzter Zeit herausgebracht hat. Mein MacBook sichert jeden Tag, jede Stunde automatisch und auf der 1 TB großen Festplatte ist auch noch genug Platz um Bilder oder Musik unterzubringen.</p>
<p>Es gibt jedoch Probleme mit einigen Druckern, welche über USB an die Time Capsule angeschlossen werden, damit man von allen Rechnern aus dem Netz darauf drucken kann. Dazu gehört auch der Samsung 2010R Laserdrucker. Mit einigen anderen Samsung Modellen besteht das Problem ebenfalls, wie ich nach einigen Recherchen herausgefunden habe.</p>
<p>Das Problem sieht wie folgt aus:  Der Drucker druckt die erste Seite über Word 2008 sofort, aber bei allen anderen Programmen dauert es viele Minuten, manchmal sogar bis zu 10 Minuten, ehe überhaupt die erste Seite gedruckt wird.</p>
<p>Folgende Lösung gibt es dafür:</p>
<ul>
<li>Samsung 2010 Drucker über USB an die Time Capsule anschließen</li>
<li>Mit dem Programm &#8220;<a href="http://www.tildesoft.com/Programs.html" title="Bonjour Browser" target="_blank">Bonjour Browser</a>&#8221; nachschauen, welche Services der Drucker benutzt</li>
<li>Ausschau halten nach &#8220;Printer PDL Data Stream&#8221;</li>
<li>Die IP und den Port merken (meistens IP: 10.0.1.1 und Port 9100)</li>
<li>Mit+ einen neuen Drucker hinzufügen</li>
<li>&#8220;IP&#8221; auswählen oben im Menu</li>
<li>Als Protokoll &#8220;HP Jetdirect &#8211; Socket&#8221; auswählen</li>
<li>Die IP-Adresse eingeben (keinen Port angeben)</li>
<li>Warteschlangennamen leer lassen!</li>
<li> Namen angeben den man möchte (Name des Druckers)</li>
<li>&#8220;Anderen Treiber&#8221; auswählen und den passenden Treiber des Druckers (hier Samsung 2010) aus  /Library/Printers/PPDs/Contents/Resources/ auswählen.</li>
<li>Hinweis: Der Druckertreiber muss natürlich vorher installiert sein, falls nicht vorhanden.</li>
</ul>
<p>Jetzt kann man wie gewohnt schnell drucken.</p>
<p>Das ist natürlich nur ein Workaround. Komischerweise ist das Problem nur bei MacOS 10.5.2, bei 10.4 kann wie gewohnt gedruckt werden. Naja, scheint wohl hoffentlich bald von Apple gefixt zu werden.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.sobek.info/blog/2008/05/25/drucken-an-der-apple-time-capsule/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

