<?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>Sehr leicht zu merken &#187; Programmieren</title>
	<atom:link href="http://web.slzm.de/blog/category/programmieren/feed/" rel="self" type="application/rss+xml" />
	<link>http://web.slzm.de/blog</link>
	<description></description>
	<lastBuildDate>Mon, 30 Jan 2012 14:47:42 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Train-Tracking für die Deutsche Bahn per Mail</title>
		<link>http://web.slzm.de/blog/programmieren/train-tracking-fur-die-deutsche-bahn-per-mail/</link>
		<comments>http://web.slzm.de/blog/programmieren/train-tracking-fur-die-deutsche-bahn-per-mail/#comments</comments>
		<pubDate>Sat, 26 Feb 2011 02:19:05 +0000</pubDate>
		<dc:creator>Johannes</dc:creator>
				<category><![CDATA[Programmieren]]></category>
		<category><![CDATA[Bahn]]></category>
		<category><![CDATA[Streik]]></category>
		<category><![CDATA[überwachen]]></category>
		<category><![CDATA[Zug verfolgen]]></category>

		<guid isPermaLink="false">http://web.slzm.de/blog/?p=364</guid>
		<description><![CDATA[In Anlehnung an mein Skript zur Webseitenüberwachung, das ich sehr erfolgreich einsetze, kommt hier noch eine Sonderedition für die Verfolgung eines Zuges der DB. Die aktuellen Verspätungen werden per Mail versendet, sobald sie sich ändern. Etwas tricky war die Entfernung &#8230; <a href="http://web.slzm.de/blog/programmieren/train-tracking-fur-die-deutsche-bahn-per-mail/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>In Anlehnung an mein Skript zur Webseitenüberwachung, das ich sehr erfolgreich einsetze, kommt hier noch eine Sonderedition für die Verfolgung eines Zuges der DB.<br />
Die aktuellen Verspätungen werden per Mail versendet, sobald sie sich ändern. Etwas tricky war die Entfernung der aktuellen Uhrzeit aus der Seite, sodass nicht minütlich versendet wird, sondern tatsächlich nur bei Neuigkeiten.<br />
Ein solcher Service stünde der Bahn gut zu Gesicht (Mailadressen zum Datensammeln werden ja fleißig abgefragt bei der Bestellung). Drauf gekommen ist aber scheinbar noch keiner…</p>
<p><span id="more-364"></span></p>
<p>(Lizenz: GPLv3)</p>
<p><code>#!/bin/bash</p>
<p># settings<br />
date="28.02.11"<br />
trainType="2" # 1=ICE, 2=EC/IC, 3=IR/D, 4=RE/RB<br />
trainID="IC 428"<br />
toAddr="mail@domain.de"; # to address for the mail</p>
<p>function wgetDownload () {<br />
	wget --post-data="productClassFilter=${trainType}&#038;date=${date}&#038;trainname=${trainID}&#038;stationFilter=80" "http://mobile.bahn.de/bin/mobil/trainsearch.exe/dox?ld=96236&#038;rt=1&#038;use_realtime_filter=1&#038;" --base="http://mobile.bahn.de/" --output-document "new.content";<br />
}</p>
<p>function cleanNewFile () {<br />
	perl -i -pe 'BEGIN{undef $/;} s/.tr class="current".*?aktuelle Zeit.*?.tr..//smg' new.content<br />
}</p>
<p>echo "Checking ${trainID}...";<br />
# generate URL's SHA1 sum and pushd to that dir<br />
urlhash=`echo "$URL" | sha1sum | sed 's/^\(\w*\)\s*\(.*\)/\1/'`;<br />
echo $urlhash;<br />
mkdir -p $urlhash;<br />
pushd $urlhash > /dev/null;</p>
<p>if [ ! -f old.content ]<br />
then<br />
	# if no file there, wget freshly<br />
	echo "No old file found.";<br />
	wgetDownload<br />
	cp "new.content" "old.content";<br />
fi</p>
<p>#echo "Old file found.";<br />
# else move old file, wget freshly<br />
rm "old.content";<br />
mv "new.content" "old.content";<br />
wgetDownload<br />
cleanNewFile</p>
<p># compare SHA1 sums of both files<br />
oldhash=`sha1sum "old.content" | sed 's/^\(\w*\)\s*\(.*\)/\1/'`;<br />
newhash=`sha1sum "new.content" | sed 's/^\(\w*\)\s*\(.*\)/\1/'`;<br />
echo $newhash" vs. "$oldhash;</p>
<p># if not the same, send mail<br />
if [ $newhash != $oldhash ]<br />
then<br />
	diff old.content new.content > diff.file;<br />
	mailcontent='Content-Type: text/html; charset="iso8859-1"<br />
'`cat new.content`;<br />
	echo "$mailcontent" | mail -s "News for ${trainID} (at "`date`")" "$toAddr";<br />
fi</p>
<p>popd > /dev/null;</code></p>
]]></content:encoded>
			<wfw:commentRss>http://web.slzm.de/blog/programmieren/train-tracking-fur-die-deutsche-bahn-per-mail/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Hopeka &#8211; Modulares Post-Install-Skript für Ubuntu</title>
		<link>http://web.slzm.de/blog/linux/hopeka-modulares-post-install-skript-fur-ubuntu/</link>
		<comments>http://web.slzm.de/blog/linux/hopeka-modulares-post-install-skript-fur-ubuntu/#comments</comments>
		<pubDate>Wed, 08 Dec 2010 18:13:41 +0000</pubDate>
		<dc:creator>Johannes</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Programmieren]]></category>
		<category><![CDATA[Ubuntu]]></category>

		<guid isPermaLink="false">http://web.slzm.de/blog/?p=312</guid>
		<description><![CDATA[Es gibt eine Menge Tweaks, die ich immer wieder anwende, wenn ich ein Ubuntu-System frisch installiert habe. Der Aufwand dafür ist aber leider unnötig hoch, weil ich meistens wieder den Blogeintrag suchen muss, in dem die relevanten ein bis zwei &#8230; <a href="http://web.slzm.de/blog/linux/hopeka-modulares-post-install-skript-fur-ubuntu/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Es gibt eine Menge Tweaks, die ich immer wieder anwende, wenn ich ein Ubuntu-System frisch installiert habe. Der Aufwand dafür ist aber leider unnötig hoch, weil ich meistens wieder den Blogeintrag suchen muss, in dem die relevanten ein bis zwei Zeilen Code standen. Dann muss ich oft noch PPAs oder andere Softwarequellen aktivieren und so weiter. Das Schlimmste ist aus meiner Sicht aber, dass apt-get auf der Kommandozeile nicht (oder zumindest nicht richtig?) queuen kann, also eine in Auftrag gegebene Installation bis zu ihrem Abschluss weitere Aufträge (!) blockiert. Außerdem werden andere Programme wie Synaptic dann garstig, weil sie keinen Lock bekommen können.<br />
<span id="more-312"></span><br />
Einige der Probleme löst Ubuntu Tweak. Das ist ein nützliches Programm und ich nutze es auch gerne, aber für die hier skizzierte Aufgabenstellung taugt es auch nur sehr bedingt: Ich kann keine eigenen Tweaks einbauen und ich kann es nicht automatisieren, muss also doch wieder selbst durch alle Eingabemasken laufen und am Rechner bleiben.</p>
<p>Also habe ich bei ubuntuusers.de meinen Plan geschildert: http://forum.ubuntuusers.de/topic/modulares-post-install-skript-fuer-maverick-en/. Leider gab es &#8212; wie ihr lesen könnt &#8212; keinerlei Feedback, sodass ich mich doch selbst ans Werk machen musste.</p>
<p>Herausgekommen ist bisher folgendes: Es gibt einen Ordner mit Bash-Skripten, die jeweils einen Tweak darstellen und die volle Bash-Macht zur Verfügung haben. Sie können also Software installieren, Einstellungen ändern und so weiter. Ein Python-Skript fragt mit Zenity-Oberfläche ab, welche der verfügbaren Tweaks angewendet werden sollen und kombiniert sie. Der Clou beim Kombinieren ist die Platzierung: Mit entsprechenden Kommentaren lassen sich quasi Abschnitte in den Skripten definieren. Das bedeutet, dass alle Zeilen aus allen Abschnitten namens &#8220;preinstall&#8221; vor allen Zeilen unter &#8220;postinstall&#8221; kommen können (beliebige weitere Abschnitte können einfach definiert werden). Durch dieses Konzept wird das entstehende Bash-Skript deutlich optimiert, es werden z.B. erst alle Paketquellen hinzugefügt, dann <em>einmal</em> ein Update der Paketlisten gefahren und dann alle Installationen auf dem aktuellen Datenbestand durchgeführt. Mit dem fertigen Bash-Skript, das keine weiteren Abhängigkeiten zieht, kann man dann auf einen neuen Ubuntu-Rechner die gewünschte Konfiguration herstellen. Ruft man hopeka erneut auf, lassen sich aber eben auch andere Auswahlen generieren.</p>
<p><strong>Testen:</strong><br />
<code>sudo apt-get install zenity<br />
cd /tmp<br />
wget http://www.brianramos.com/software/PyZenity/PyZenity-0.1.5.tar.gz<br />
gunzip -c PyZenity-0.1.5.tar.gz | tar xf -    # unpacks into directory foo-1.0<br />
cd PyZenity-0.1.5<br />
python setup.py install</code><br />
(Danke an <a href="http://www.brianramos.com/?page_id=110">Brian Ramos</a>)</p>
<p><strong>Zum Ausführen:</strong><br />
<code>chmod +x hopeka.py<br />
./hopeka.py</code></p>
<p>Tests erfolgen natürlich auf eigene Gefahr, aber zumindest das Erzeugen das gesammelten Bash-Skriptes sollte nichts zerstören.</p>
<p><strong>Lizenz:</strong><br />
Das Skript steht unter GPLv3.</p>
<p>Über Rückmeldung freue ich mich. Sollte es ernsthaftes Interesse geben und das Konzept tragfähig sein, dann wäre ich gerne bereit, ein Git(Hub)-Repository zu eröffnen, in dem wir Tweaks sammeln könnten.</p>
<p><strong>Download:</strong><br />
<a href='http://web.slzm.de/blog/wp-content/uploads/hopeka-20101208.zip'>hopeka-20101208</a></p>
<p>Johannes</p>
]]></content:encoded>
			<wfw:commentRss>http://web.slzm.de/blog/linux/hopeka-modulares-post-install-skript-fur-ubuntu/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Backup Firefox-Bookmarks</title>
		<link>http://web.slzm.de/blog/linux/backup-firefox-bookmarks/</link>
		<comments>http://web.slzm.de/blog/linux/backup-firefox-bookmarks/#comments</comments>
		<pubDate>Tue, 07 Dec 2010 15:48:12 +0000</pubDate>
		<dc:creator>Johannes</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Programmieren]]></category>
		<category><![CDATA[Ubuntu]]></category>
		<category><![CDATA[Backup]]></category>
		<category><![CDATA[Download]]></category>
		<category><![CDATA[Favoriten]]></category>
		<category><![CDATA[Herunterladen]]></category>
		<category><![CDATA[Lesezeichen]]></category>
		<category><![CDATA[Save]]></category>
		<category><![CDATA[Speichern]]></category>

		<guid isPermaLink="false">http://web.slzm.de/blog/?p=291</guid>
		<description><![CDATA[Ich bin paranoid und falls doch irgendwann mal das Internet ausfällt oder &#8212; realistischer &#8212; Inhalte aus meinen Lesezeichen verschwinden, möchte ich vorbereitet sein. Daher wollte ich ein Backup der Inhalte meiner Lesezeichen machen. Der Firefox kann die Links im &#8230; <a href="http://web.slzm.de/blog/linux/backup-firefox-bookmarks/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Ich bin paranoid und falls doch irgendwann mal das Internet ausfällt oder &#8212; realistischer &#8212; Inhalte aus meinen Lesezeichen verschwinden, möchte ich vorbereitet sein. Daher wollte ich ein Backup der <strong>Inhalte</strong> meiner Lesezeichen machen. Der Firefox kann die <strong>Links</strong> im Lesezeichenmanager einfach als Datei mit dem Namen bookmarks.html exportieren.</p>
<p><span id="more-291"></span><br />
Aus dieser Datei kann man unter Ubuntu (oder wohl auch anderen Linuxen) mit etwas Aufwand, aber dafür vollautomatisch die Seiten einzeln herunterladen zum Archivieren. Dazu reicht folgender Einzeiler:</p>
<p><code>cat bookmarks.html | grep -o "[a-zA-Z_]*=\"http[^\"]*\"" | grep -v "ICON_URI" | grep -o "\"http[^\"]*\"" | xargs wget --page-requisites --limit-rate=10m --user-agent="Mozilla/5.0 (X11; U; Linux i686; de-DE; rv:1.9.0.3) Gecko/2010112416 Firefox/3.6.3" --tries=2 --timeout=20</code></p>
<p>Genutzt wird cat zum Auslesen der Lesezeichen-Datei, die der Firefox exportiert hat, wget für den Download und mehrfach grep zum Finden der (relevanten) Links in der Liste. Dabei nutze ich drei Aufrufe, damit die Favicons sauber herausgefiltert werden können.</p>
<p>Viel Spaß mit dem kleinen Tool!</p>
<p>p.s. Das Skript sollte ich wohl auch an die Internetausdrucker in meiner Regierung schicken…</p>
]]></content:encoded>
			<wfw:commentRss>http://web.slzm.de/blog/linux/backup-firefox-bookmarks/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Webseiten von Server aus überwachen mit Mailbenachrichtigung</title>
		<link>http://web.slzm.de/blog/linux/webseiten-von-server-aus-uberwachen-mit-mailbenachrichtigung/</link>
		<comments>http://web.slzm.de/blog/linux/webseiten-von-server-aus-uberwachen-mit-mailbenachrichtigung/#comments</comments>
		<pubDate>Sat, 02 Oct 2010 15:27:33 +0000</pubDate>
		<dc:creator>Johannes</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Programmieren]]></category>
		<category><![CDATA[Ubuntu]]></category>

		<guid isPermaLink="false">http://web.slzm.de/blog/?p=220</guid>
		<description><![CDATA[Specto ist auf einem Desktop-Ubuntu-Computer eine sehr nützliche Anwendung: Sie kann beliebige Webseiten auf Änderungen überwachen, auch solche, die keinen RSS-Feed anbieten. Weitere Möglichkeiten gibt es auch, auf die soll hier aber nicht eingegangen werden &#8212; nichtsdestotrotz ist das Programm &#8230; <a href="http://web.slzm.de/blog/linux/webseiten-von-server-aus-uberwachen-mit-mailbenachrichtigung/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><a href="http://specto.sourceforge.net/">Specto</a> ist auf einem Desktop-Ubuntu-Computer eine sehr nützliche Anwendung: Sie kann beliebige Webseiten auf Änderungen überwachen, auch solche, die keinen RSS-Feed anbieten. Weitere Möglichkeiten gibt es auch, auf die soll hier aber nicht eingegangen werden &#8212; nichtsdestotrotz ist das Programm auch eine Empfehlung. Mein Blackberry läuft natürlich nicht unter Ubuntu, daher hilft mir Specto unterwegs reichlich wenig. Es muss also eine andere Lösung her, z.B. auf Basis meines Servers, der sowohl 24 Stunden am Tag läuft als auch in der Lage ist, E-Mails zu senden, die wiederum das Smartphone überall erreichen. </p>
<p><span id="more-220"></span>
<p>Die Lösung basiert wie so oft bei Linux auf dem Baukastenprinzip. Man nehme wget als ausgereifte Lösung zum Download von Webseiten, den Cron-Dämon, um mein Programm alle 5 Minuten zu starten, sha1sum zum sicheren Vergleichen von Dateien und Unterscheiden von Texten und etwas Bash-Code als Kleber und für die Anwendungslogik. Das Ergebnis sieht so aus: </p>
<pre>#!/bin/bash

# settings
URLs=( &quot;http://web.slzm.de/blog&quot; &quot;http://www.linuxundich.de&quot; ); # URLs to check
toAddr=&quot;blog@yourdomain.de&quot;; # to address for the mail

# for loop
for URL in ${URLs[@]}
do
echo &quot;Checking $URL...&quot;;
# generate URL's SHA1 sum and pushd to that dir
urlhash=`echo &quot;$URL&quot; | sha1sum | sed 's/^\(\w*\)\s*\(.*\)/\1/'`;
echo $urlhash;
mkdir -p $urlhash;
pushd $urlhash &gt; /dev/null;

if [ ! -f old.content ]
then
# if no file there, wget freshly
echo &quot;No old file found.&quot;;
wget &quot;$URL&quot;  -O &quot;new.content&quot;;
cp &quot;new.content&quot; &quot;old.content&quot;;
fi

# else move old file, wget freshly
rm &quot;old.content&quot;;
mv &quot;new.content&quot; &quot;old.content&quot;;
wget &quot;$URL&quot; -O &quot;new.content&quot;;

# compare SHA1 sums of both files
oldhash=`sha1sum &quot;old.content&quot; | sed 's/^\(\w*\)\s*\(.*\)/\1/'`;
newhash=`sha1sum &quot;new.content&quot; | sed 's/^\(\w*\)\s*\(.*\)/\1/'`;
echo $newhash&quot; vs. &quot;$oldhash;

# if not the same, send mail
if [    $newhash != $oldhash ]
then
mailcontent=&quot;$URL changed at &quot;`date`;
echo &quot;$mailcontent&quot; | mail -s &quot;URL changed: $URL&quot; &quot;$toAddr&quot;;
fi

popd &gt; /dev/null;
done</pre>
<p>Das Skript gibt es <a href="http://web.slzm.de/blog/wp-content/uploads/updatemailer.sh.zip">hier</a> zum Download. Nach dem Download einfach auspacken und mit <strong>chmod +x updatemailer.sh</strong> ausführbar machen. Nach dem Ändern der Mailadresse und der zu überprüfenden Webseiten (man beachte die krude Bash-Syntax für Arrays: kein Komma!) erfolgt ein Eintrag in die Crontab dann per <strong>sudo crontab -e</strong>. Die kann nach Ergänzungen der SHELL- und PATH-Variablen und des Skripteintrages folgendermaßen aussehen: </p>
<pre>#-----------------------------------------------------------------
# Shell variable for cron
SHELL=/bin/bash
# PATH variable for cron
PATH=/usr/local/bin:/usr/local/sbin:/sbin:/usr/sbin:/bin:/usr/bin:/usr/bin/X11
#-----------------------------------------------------------------
*/5 * * * *     /usr/bin/updatemailer/updatemailer.sh &gt; /dev/null 2&gt;&amp;1
</pre>
<p>Wichtig ist die Leerzeile am Ende. Speichern und verlassen muss man den Editor über <strong>Strg+k</strong>, gefolgt von <strong>x</strong>.<strong> </strong>Zum Abschluss ein Cron-Neustart mit<strong> sudo /etc/init.d/cron restart</strong> und schon sollten die Mails eintrudeln, wenn sich etwas ändert. Viel Erfolg!</p>
]]></content:encoded>
			<wfw:commentRss>http://web.slzm.de/blog/linux/webseiten-von-server-aus-uberwachen-mit-mailbenachrichtigung/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Klappe, die Dritte &#8211; AutoIt-Buch unter CC-Lizenz</title>
		<link>http://web.slzm.de/blog/latex/klappe-die-dritte-autoit-buch-unter-cc-lizenz/</link>
		<comments>http://web.slzm.de/blog/latex/klappe-die-dritte-autoit-buch-unter-cc-lizenz/#comments</comments>
		<pubDate>Wed, 29 Sep 2010 20:48:55 +0000</pubDate>
		<dc:creator>Johannes</dc:creator>
				<category><![CDATA[AutoIt]]></category>
		<category><![CDATA[LaTeX]]></category>
		<category><![CDATA[Programmieren]]></category>
		<category><![CDATA[AutoIt leicht gemacht]]></category>
		<category><![CDATA[Buch]]></category>
		<category><![CDATA[Download]]></category>
		<category><![CDATA[Einführung]]></category>
		<category><![CDATA[free]]></category>
		<category><![CDATA[kostenlos]]></category>

		<guid isPermaLink="false">http://web.slzm.de/blog/?p=201</guid>
		<description><![CDATA[Es gibt wieder Neuigkeiten aus der Buchabteilung. Vorherige Version siehe hier. Die technische Überarbeitung des Buches ist extrem. Ich möchte eigentlich immer nur die beste Lösung einsetzen, den zukunftsträchtigsten Ansatz, das sauberste technische Design. Daher gibt es jetzt einige Veränderungen &#8230; <a href="http://web.slzm.de/blog/latex/klappe-die-dritte-autoit-buch-unter-cc-lizenz/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Es gibt wieder Neuigkeiten aus der Buchabteilung. Vorherige Version siehe <a href="http://web.slzm.de/blog/latex/autoit-buch-episode-ii/">hier</a>.<span id="more-201"></span></p>
<p>Die technische Überarbeitung des Buches ist extrem. Ich möchte eigentlich immer nur die beste Lösung einsetzen, den zukunftsträchtigsten Ansatz, das sauberste technische Design. Daher gibt es jetzt einige Veränderungen unter der Haube. Vom klassischen pdfLatex bin ich zum fortschrittlichen (UTF8!) XeTeX übergelaufen und habe es nicht bereut. Im PDF ist das am augenfälligsten durch eine neue Schriftart.<br />
Außerdem habe ich die Boxen nach einem hervorragenden Hinweis von <a href="http://my.opera.com/freedo/blog/hinweis" target="_blank">http://my.opera.com/freedo/blog/hinweis</a> optisch extrem aufgewertet. Vielen Dank für diese Idee!<br />
Zusätzlich gibt es ein neues (grün-stichiges) Titelbild für die Webausgabe. Ein handgemaltes A ziert den Hintergrund hoffentlich. Konzeptuell sollen die wechselnden Farben der Titelblätter übrigens eine einfache Unterscheidung ermöglichen, aus welchem Zeitabschnitt ein Exemplar stammt.</p>
<p>Das Highlight dieser Ausgabe ist &#8212; wie könnte es anders sein &#8212; das (Syntax-)Highlighting. Endlich habe ich da einen Weg gefunden, den ich technisch mit meinem Perfektionsanspruch vereinbaren kann. Es basiert auf dem OpenSource-Tool &#8220;highlight&#8221; (von <a href="http://www.andre-simon.de/" target="_blank">http://www.andre-simon.de/</a>) und ein paar eigenen Bash-Skripten und Kommandos für XeTeX. Diesen Teil werde ich bei Gelegenheit in eigenen Blogartikel gießen, damit andere davon auch profitieren können, denn das Anzeigen von Quelltexten ist leider in La- und XeTeX immer noch kein Spaß.</p>
<p>Die inhaltlichen Änderungen halten sich diesmal deutlich im Rahmen. Hauptsächlich habe ich das geändert, was beim Durchlesen und technischen Testen sowohl auffiel als auch unkompliziert zu ändern war. Einige der Hinweise aus den Kommentaren zur letzten Version habe ich eingebaut, vielen Dank allen Helfern!</p>
<p>Jetzt aber genug der Worte, Download: <a href="http://web.slzm.de/blog/wp-content/uploads/AutoIt_leicht_gemacht_web_20100929.pdf">AutoIt leicht gemacht (29. September 2010)</a></p>
<p>Wenn das Buch jemandem gefällt und etwas gebracht hat, freue ich mich über eine Kleinigkeit von meinem <a href="http://www.amazon.de/wishlist/2SF4DT3OOLQMF">Amazon-Wunschzettel</a>. Danke!</p>
]]></content:encoded>
			<wfw:commentRss>http://web.slzm.de/blog/latex/klappe-die-dritte-autoit-buch-unter-cc-lizenz/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Führende Zeilennummern entfernen</title>
		<link>http://web.slzm.de/blog/linux/fuhrende-zeilennummern-entfernen/</link>
		<comments>http://web.slzm.de/blog/linux/fuhrende-zeilennummern-entfernen/#comments</comments>
		<pubDate>Wed, 02 Jun 2010 10:31:20 +0000</pubDate>
		<dc:creator>Johannes</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Programmieren]]></category>
		<category><![CDATA[Ubuntu]]></category>

		<guid isPermaLink="false">http://web.slzm.de/blog/?p=185</guid>
		<description><![CDATA[Mancher Texteditor und manche Webseite ist ja der Meinung, dass Code mit Zeilennummern versehen werden sollte. Das ist prinzipiell auch meine Meinung, allerdings nervt es tierisch, wenn dann beim Rauskopieren die Zeilennummern (die ja nur Metainformation sind) mitwandern. Die Lösung &#8230; <a href="http://web.slzm.de/blog/linux/fuhrende-zeilennummern-entfernen/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Mancher Texteditor und manche Webseite ist ja der Meinung, dass Code mit Zeilennummern versehen werden sollte. Das ist prinzipiell auch meine Meinung, allerdings nervt es tierisch, wenn dann beim Rauskopieren die Zeilennummern (die ja nur Metainformation sind) mitwandern.</p>
<p>Die Lösung ist für mich vorläufig das hier:<br />
<code>cat file.txt | sed -e 's,^[0-9]*,,' > file2.txt</code></p>
<p>Quelle:<br />
<a href="http://txt.binnyva.com/2009/05/delete-leading-whitespace-using-sed/">http://txt.binnyva.com/2009/05/delete-leading-whitespace-using-sed/</a></p>
]]></content:encoded>
			<wfw:commentRss>http://web.slzm.de/blog/linux/fuhrende-zeilennummern-entfernen/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Suche nach einem Text in allen Dateien inkl. Unterordner</title>
		<link>http://web.slzm.de/blog/linux/suche-nach-einem-text-in-allen-dateien-inkl-unterordner/</link>
		<comments>http://web.slzm.de/blog/linux/suche-nach-einem-text-in-allen-dateien-inkl-unterordner/#comments</comments>
		<pubDate>Sun, 19 Jul 2009 10:55:31 +0000</pubDate>
		<dc:creator>Johannes</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Programmieren]]></category>
		<category><![CDATA[Ubuntu]]></category>
		<category><![CDATA[Dateien]]></category>
		<category><![CDATA[Ordner]]></category>
		<category><![CDATA[Suche]]></category>
		<category><![CDATA[Texte]]></category>
		<category><![CDATA[Unterordner]]></category>

		<guid isPermaLink="false">http://web.slzm.de/blog/?p=139</guid>
		<description><![CDATA[Ubuntuverse.at hat einen Tipp, der für mich Gold wert ist. Gerade unter Windows habe ich es oft vermisst (und erinnere mich an mehrfaches erfolgloses Googlen nach einer externen Freeware-Lösung), in allen Dateien eines Ordners (und seiner Unterordner) nach einem Text &#8230; <a href="http://web.slzm.de/blog/linux/suche-nach-einem-text-in-allen-dateien-inkl-unterordner/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.ubuntuverse.at">Ubuntuverse.at</a> hat einen Tipp, der für mich Gold wert ist. Gerade unter Windows habe ich es oft vermisst (und erinnere mich an mehrfaches erfolgloses Googlen nach einer externen Freeware-Lösung), in allen Dateien eines Ordners (und seiner Unterordner) nach einem Text zu suchen.</p>
<p><span id="more-139"></span></p>
<p>Hier ist der Code dafür unter Ubuntu:</p>
<pre>find . -name * -exec grep -i 'TEXT' '{}' ';'</pre>
<p>Quelle: <a href="http://www.ubuntuverse.at/2009/07/19/diese-woche-in-der-konsole-3/">http://www.ubuntuverse.at/2009/07/19/diese-woche-in-der-konsole-3/</a></p>
]]></content:encoded>
			<wfw:commentRss>http://web.slzm.de/blog/linux/suche-nach-einem-text-in-allen-dateien-inkl-unterordner/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Aufzählungen von Word/HTML nach LaTeX konvertieren</title>
		<link>http://web.slzm.de/blog/latex/aufzahlungen-von-wordhtml-nach-latex-konvertieren/</link>
		<comments>http://web.slzm.de/blog/latex/aufzahlungen-von-wordhtml-nach-latex-konvertieren/#comments</comments>
		<pubDate>Sat, 18 Jul 2009 13:50:34 +0000</pubDate>
		<dc:creator>Johannes</dc:creator>
				<category><![CDATA[AutoIt]]></category>
		<category><![CDATA[LaTeX]]></category>
		<category><![CDATA[Programmieren]]></category>

		<guid isPermaLink="false">http://web.slzm.de/blog/?p=129</guid>
		<description><![CDATA[Das folgende Skript habe ich mir gebastelt, um Word-Aufzählungen in LaTeX zu konvertieren. Gerade wenn es mehrere Ebenen sind, ist es in Word einfach jedes Mal wieder nervig, die Ebenen zu koordinieren. Als das aktuelle (!) Word 2007 es dann &#8230; <a href="http://web.slzm.de/blog/latex/aufzahlungen-von-wordhtml-nach-latex-konvertieren/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Das folgende Skript habe ich mir gebastelt, um Word-Aufzählungen in LaTeX zu konvertieren. Gerade wenn es mehrere Ebenen sind, ist es in Word einfach jedes Mal wieder nervig, die Ebenen zu koordinieren. Als das aktuelle (!) Word 2007 es dann doch geschafft hat, Einzüge zu machen, wo sie keinen Sinn machen, hat es gereicht und ordentlicher Textsatz musste her &#8212; LaTeX.</p>
<p><span id="more-129"></span>Hier das <a href="http://www.autoit.de">AutoIt</a>-Skript, dass die Konvertierung besorgt:</p>

<div class="wp_syntax"><div class="code"><pre class="autoit" style="font-family:monospace;"><span style="color: #F000FF; font-style: italic;">#include</span><span style="font-style: italic; color: #9977BB;"> &lt;file.au3&gt;</span>
<span style="color: #F000FF; font-style: italic;">#include</span><span style="font-style: italic; color: #9977BB;"> &lt;array.au3&gt;</span>
&nbsp;
<span style="font-style: italic; color: #009933;">; Definitions</span>
<span style="color: #0000FF; font-weight: bold;">Global</span> <span style="font-weight: bold; color: #AA0000;">$lvlMatch</span><span style="color: #FF0000; font-weight: bold;">&#91;</span><span style="color: #AC00A9; font-style: italic; font-weight: bold;">4</span><span style="color: #FF0000; font-weight: bold;">&#93;</span> <span style="color: #FF0000; font-weight: bold;">=</span> <span style="color: #FF0000; font-weight: bold;">&#91;</span><span style="font-weight: bold; color: #9977BB;">&quot;^\s*\d*\.\s*(.*)&quot;</span><span style="color: #FF0000; font-weight: bold;">,</span> <span style="font-weight: bold; color: #9977BB;">&quot;^\s*[a-z]\.\s*(.*)&quot;</span><span style="color: #FF0000; font-weight: bold;">,</span> <span style="font-weight: bold; color: #9977BB;">&quot;^\s*[ivx]*\.\s*(.*)&quot;</span><span style="color: #FF0000; font-weight: bold;">,</span> <span style="font-weight: bold; color: #9977BB;">&quot;^\s*\d*\.\s*(.*)&quot;</span><span style="color: #FF0000; font-weight: bold;">&#93;</span>
<span style="color: #0000FF; font-weight: bold;">Global</span> <span style="font-weight: bold; color: #AA0000;">$data</span>
<span style="color: #0080FF; font-style: italic; font-weight: bold;">_FileReadToArray</span><span style="color: #FF0000; font-weight: bold;">&#40;</span><span style="color: #800000; font-weight: bold;"><span style="font-weight: bold; color: #AA0000;">@ScriptDir</span></span> <span style="color: #FF0000; font-weight: bold;">&amp;</span> <span style="font-weight: bold; color: #9977BB;">&quot;\input.txt&quot;</span><span style="color: #FF0000; font-weight: bold;">,</span> <span style="font-weight: bold; color: #AA0000;">$data</span><span style="color: #FF0000; font-weight: bold;">&#41;</span>
<span style="color: #0080FF; font-style: italic; font-weight: bold;">_ArrayDelete</span><span style="color: #FF0000; font-weight: bold;">&#40;</span><span style="font-weight: bold; color: #AA0000;">$data</span><span style="color: #FF0000; font-weight: bold;">,</span> <span style="color: #AC00A9; font-style: italic; font-weight: bold;">0</span><span style="color: #FF0000; font-weight: bold;">&#41;</span>
<span style="color: #0000FF; font-weight: bold;">Global</span> <span style="font-weight: bold; color: #AA0000;">$levels</span><span style="color: #FF0000; font-weight: bold;">&#91;</span><span style="color: #000080; font-style: italic; font-weight: bold;">UBound</span><span style="color: #FF0000; font-weight: bold;">&#40;</span><span style="font-weight: bold; color: #AA0000;">$data</span><span style="color: #FF0000; font-weight: bold;">&#41;</span><span style="color: #FF0000; font-weight: bold;">&#93;</span>
&nbsp;
<span style="font-style: italic; color: #009933;">; Levels herausfinden</span>
<span style="color: #0000FF; font-weight: bold;">For</span> <span style="font-weight: bold; color: #AA0000;">$i</span> <span style="color: #FF0000; font-weight: bold;">=</span> <span style="color: #AC00A9; font-style: italic; font-weight: bold;">0</span> <span style="color: #0000FF; font-weight: bold;">To</span> <span style="color: #000080; font-style: italic; font-weight: bold;">UBound</span><span style="color: #FF0000; font-weight: bold;">&#40;</span><span style="font-weight: bold; color: #AA0000;">$data</span><span style="color: #FF0000; font-weight: bold;">&#41;</span> <span style="color: #FF0000; font-weight: bold;">-</span> <span style="color: #AC00A9; font-style: italic; font-weight: bold;">1</span>
	<span style="font-weight: bold; color: #AA0000;">$levels</span><span style="color: #FF0000; font-weight: bold;">&#91;</span><span style="font-weight: bold; color: #AA0000;">$i</span><span style="color: #FF0000; font-weight: bold;">&#93;</span> <span style="color: #FF0000; font-weight: bold;">=</span> <span style="color: #FF0000; font-weight: bold;">-</span><span style="color: #AC00A9; font-style: italic; font-weight: bold;">1</span> <span style="font-style: italic; color: #009933;">; Default (= no explicit match)</span>
	<span style="color: #0000FF; font-weight: bold;">For</span> <span style="font-weight: bold; color: #AA0000;">$j</span> <span style="color: #FF0000; font-weight: bold;">=</span> <span style="color: #000080; font-style: italic; font-weight: bold;">UBound</span><span style="color: #FF0000; font-weight: bold;">&#40;</span><span style="font-weight: bold; color: #AA0000;">$lvlMatch</span><span style="color: #FF0000; font-weight: bold;">&#41;</span> <span style="color: #FF0000; font-weight: bold;">-</span> <span style="color: #AC00A9; font-style: italic; font-weight: bold;">1</span> <span style="color: #0000FF; font-weight: bold;">To</span> <span style="color: #AC00A9; font-style: italic; font-weight: bold;">0</span> <span style="color: #0000FF; font-weight: bold;">Step</span> <span style="color: #FF0000; font-weight: bold;">-</span><span style="color: #AC00A9; font-style: italic; font-weight: bold;">1</span> <span style="font-style: italic; color: #009933;">; zu hoch raten im Notfall</span>
		<span style="color: #0000FF; font-weight: bold;">If</span> <span style="color: #000080; font-style: italic; font-weight: bold;">StringRegExp</span><span style="color: #FF0000; font-weight: bold;">&#40;</span><span style="font-weight: bold; color: #AA0000;">$data</span><span style="color: #FF0000; font-weight: bold;">&#91;</span><span style="font-weight: bold; color: #AA0000;">$i</span><span style="color: #FF0000; font-weight: bold;">&#93;</span><span style="color: #FF0000; font-weight: bold;">,</span> <span style="font-weight: bold; color: #AA0000;">$lvlMatch</span><span style="color: #FF0000; font-weight: bold;">&#91;</span><span style="font-weight: bold; color: #AA0000;">$j</span><span style="color: #FF0000; font-weight: bold;">&#93;</span><span style="color: #FF0000; font-weight: bold;">,</span> <span style="color: #AC00A9; font-style: italic; font-weight: bold;">0</span><span style="color: #FF0000; font-weight: bold;">&#41;</span> <span style="color: #0000FF; font-weight: bold;">Then</span>
			<span style="font-weight: bold; color: #AA0000;">$levels</span><span style="color: #FF0000; font-weight: bold;">&#91;</span><span style="font-weight: bold; color: #AA0000;">$i</span><span style="color: #FF0000; font-weight: bold;">&#93;</span> <span style="color: #FF0000; font-weight: bold;">=</span> <span style="font-weight: bold; color: #AA0000;">$j</span>
			<span style="font-weight: bold; color: #AA0000;">$data</span><span style="color: #FF0000; font-weight: bold;">&#91;</span><span style="font-weight: bold; color: #AA0000;">$i</span><span style="color: #FF0000; font-weight: bold;">&#93;</span> <span style="color: #FF0000; font-weight: bold;">=</span> <span style="color: #000080; font-style: italic; font-weight: bold;">StringRegExpReplace</span><span style="color: #FF0000; font-weight: bold;">&#40;</span><span style="font-weight: bold; color: #AA0000;">$data</span><span style="color: #FF0000; font-weight: bold;">&#91;</span><span style="font-weight: bold; color: #AA0000;">$i</span><span style="color: #FF0000; font-weight: bold;">&#93;</span><span style="color: #FF0000; font-weight: bold;">,</span> <span style="font-weight: bold; color: #AA0000;">$lvlMatch</span><span style="color: #FF0000; font-weight: bold;">&#91;</span><span style="font-weight: bold; color: #AA0000;">$j</span><span style="color: #FF0000; font-weight: bold;">&#93;</span><span style="color: #FF0000; font-weight: bold;">,</span> <span style="font-weight: bold; color: #9977BB;">&quot;\1&quot;</span><span style="color: #FF0000; font-weight: bold;">,</span> <span style="color: #AC00A9; font-style: italic; font-weight: bold;">1</span><span style="color: #FF0000; font-weight: bold;">&#41;</span>
			<span style="color: #0000FF; font-weight: bold;">ContinueLoop</span> <span style="color: #AC00A9; font-style: italic; font-weight: bold;">2</span>
		<span style="color: #0000FF; font-weight: bold;">EndIf</span>
	<span style="color: #0000FF; font-weight: bold;">Next</span>
<span style="color: #0000FF; font-weight: bold;">Next</span>
&nbsp;
<span style="font-style: italic; color: #009933;">; 0/3-Fix</span>
<span style="color: #0080FF; font-style: italic; font-weight: bold;">_ArrayInsert</span><span style="color: #FF0000; font-weight: bold;">&#40;</span><span style="font-weight: bold; color: #AA0000;">$data</span><span style="color: #FF0000; font-weight: bold;">,</span> <span style="color: #AC00A9; font-style: italic; font-weight: bold;">0</span><span style="color: #FF0000; font-weight: bold;">,</span> <span style="font-weight: bold; color: #9977BB;">&quot;&quot;</span><span style="color: #FF0000; font-weight: bold;">&#41;</span>
<span style="color: #0080FF; font-style: italic; font-weight: bold;">_ArrayInsert</span><span style="color: #FF0000; font-weight: bold;">&#40;</span><span style="font-weight: bold; color: #AA0000;">$levels</span><span style="color: #FF0000; font-weight: bold;">,</span> <span style="color: #AC00A9; font-style: italic; font-weight: bold;">0</span><span style="color: #FF0000; font-weight: bold;">,</span> <span style="color: #FF0000; font-weight: bold;">-</span><span style="color: #AC00A9; font-style: italic; font-weight: bold;">1</span><span style="color: #FF0000; font-weight: bold;">&#41;</span>
&nbsp;
<span style="color: #0000FF; font-weight: bold;">For</span> <span style="font-weight: bold; color: #AA0000;">$i</span> <span style="color: #FF0000; font-weight: bold;">=</span> <span style="color: #AC00A9; font-style: italic; font-weight: bold;">1</span> <span style="color: #0000FF; font-weight: bold;">To</span> <span style="color: #000080; font-style: italic; font-weight: bold;">UBound</span><span style="color: #FF0000; font-weight: bold;">&#40;</span><span style="font-weight: bold; color: #AA0000;">$data</span><span style="color: #FF0000; font-weight: bold;">&#41;</span> <span style="color: #FF0000; font-weight: bold;">-</span> <span style="color: #AC00A9; font-style: italic; font-weight: bold;">2</span> <span style="font-style: italic; color: #009933;">; !</span>
	<span style="color: #0000FF; font-weight: bold;">If</span> <span style="color: #FF0000; font-weight: bold;">&#40;</span><span style="color: #FF0000; font-weight: bold;">&#40;</span><span style="font-weight: bold; color: #AA0000;">$levels</span><span style="color: #FF0000; font-weight: bold;">&#91;</span><span style="font-weight: bold; color: #AA0000;">$i</span><span style="color: #FF0000; font-weight: bold;">&#93;</span> <span style="color: #FF0000; font-weight: bold;">=</span> <span style="color: #AC00A9; font-style: italic; font-weight: bold;">3</span><span style="color: #FF0000; font-weight: bold;">&#41;</span> <span style="color: #0000FF; font-weight: bold;">And</span> <span style="color: #FF0000; font-weight: bold;">&#40;</span><span style="font-weight: bold; color: #AA0000;">$levels</span><span style="color: #FF0000; font-weight: bold;">&#91;</span><span style="font-weight: bold; color: #AA0000;">$i</span> <span style="color: #FF0000; font-weight: bold;">+</span> <span style="color: #AC00A9; font-style: italic; font-weight: bold;">1</span><span style="color: #FF0000; font-weight: bold;">&#93;</span> <span style="color: #FF0000; font-weight: bold;">=</span> <span style="color: #AC00A9; font-style: italic; font-weight: bold;">1</span><span style="color: #FF0000; font-weight: bold;">&#41;</span><span style="color: #FF0000; font-weight: bold;">&#41;</span> <span style="color: #0000FF; font-weight: bold;">OR</span> <span style="color: #FF0000; font-weight: bold;">&#40;</span><span style="color: #FF0000; font-weight: bold;">&#40;</span><span style="font-weight: bold; color: #AA0000;">$levels</span><span style="color: #FF0000; font-weight: bold;">&#91;</span><span style="font-weight: bold; color: #AA0000;">$i</span><span style="color: #FF0000; font-weight: bold;">&#93;</span> <span style="color: #FF0000; font-weight: bold;">=</span> <span style="color: #AC00A9; font-style: italic; font-weight: bold;">3</span><span style="color: #FF0000; font-weight: bold;">&#41;</span> <span style="color: #0000FF; font-weight: bold;">And</span> <span style="color: #FF0000; font-weight: bold;">&#40;</span><span style="color: #000080; font-style: italic; font-weight: bold;">StringRegExp</span><span style="color: #FF0000; font-weight: bold;">&#40;</span><span style="font-weight: bold; color: #AA0000;">$data</span><span style="color: #FF0000; font-weight: bold;">&#91;</span><span style="font-weight: bold; color: #AA0000;">$i</span> <span style="color: #FF0000; font-weight: bold;">-</span> <span style="color: #AC00A9; font-style: italic; font-weight: bold;">1</span><span style="color: #FF0000; font-weight: bold;">&#93;</span><span style="color: #FF0000; font-weight: bold;">,</span> <span style="font-weight: bold; color: #9977BB;">&quot;^\s*$&quot;</span><span style="color: #FF0000; font-weight: bold;">,</span> <span style="color: #AC00A9; font-style: italic; font-weight: bold;">0</span><span style="color: #FF0000; font-weight: bold;">&#41;</span><span style="color: #FF0000; font-weight: bold;">&#41;</span><span style="color: #FF0000; font-weight: bold;">&#41;</span> <span style="color: #0000FF; font-weight: bold;">Then</span>
		<span style="font-weight: bold; color: #AA0000;">$levels</span><span style="color: #FF0000; font-weight: bold;">&#91;</span><span style="font-weight: bold; color: #AA0000;">$i</span><span style="color: #FF0000; font-weight: bold;">&#93;</span> <span style="color: #FF0000; font-weight: bold;">=</span> <span style="color: #AC00A9; font-style: italic; font-weight: bold;">0</span>
	<span style="color: #0000FF; font-weight: bold;">EndIf</span>
<span style="color: #0000FF; font-weight: bold;">Next</span>
&nbsp;
<span style="font-style: italic; color: #009933;">; Fix für Ende</span>
<span style="color: #0080FF; font-style: italic; font-weight: bold;">_ArrayAdd</span><span style="color: #FF0000; font-weight: bold;">&#40;</span><span style="font-weight: bold; color: #AA0000;">$data</span><span style="color: #FF0000; font-weight: bold;">,</span> <span style="font-weight: bold; color: #9977BB;">&quot;&quot;</span><span style="color: #FF0000; font-weight: bold;">&#41;</span>
<span style="color: #0080FF; font-style: italic; font-weight: bold;">_ArrayAdd</span><span style="color: #FF0000; font-weight: bold;">&#40;</span><span style="font-weight: bold; color: #AA0000;">$levels</span><span style="color: #FF0000; font-weight: bold;">,</span> <span style="color: #AC00A9; font-style: italic; font-weight: bold;">0</span><span style="color: #FF0000; font-weight: bold;">&#41;</span>
&nbsp;
<span style="font-style: italic; color: #009933;">; Output generieren</span>
<span style="font-weight: bold; color: #AA0000;">$currLevel</span> <span style="color: #FF0000; font-weight: bold;">=</span> <span style="color: #FF0000; font-weight: bold;">-</span><span style="color: #AC00A9; font-style: italic; font-weight: bold;">1</span>
<span style="font-weight: bold; color: #AA0000;">$output</span> <span style="color: #FF0000; font-weight: bold;">=</span> <span style="font-weight: bold; color: #9977BB;">&quot;&quot;</span>
<span style="color: #0000FF; font-weight: bold;">For</span> <span style="font-weight: bold; color: #AA0000;">$i</span> <span style="color: #FF0000; font-weight: bold;">=</span> <span style="color: #AC00A9; font-style: italic; font-weight: bold;">0</span> <span style="color: #0000FF; font-weight: bold;">To</span> <span style="color: #000080; font-style: italic; font-weight: bold;">UBound</span><span style="color: #FF0000; font-weight: bold;">&#40;</span><span style="font-weight: bold; color: #AA0000;">$data</span><span style="color: #FF0000; font-weight: bold;">&#41;</span> <span style="color: #FF0000; font-weight: bold;">-</span> <span style="color: #AC00A9; font-style: italic; font-weight: bold;">1</span>
	<span style="font-weight: bold; color: #AA0000;">$newLevel</span> <span style="color: #FF0000; font-weight: bold;">=</span> <span style="font-weight: bold; color: #AA0000;">$levels</span><span style="color: #FF0000; font-weight: bold;">&#91;</span><span style="font-weight: bold; color: #AA0000;">$i</span><span style="color: #FF0000; font-weight: bold;">&#93;</span>
	<span style="color: #0000FF; font-weight: bold;">If</span> <span style="font-weight: bold; color: #AA0000;">$newLevel</span> <span style="color: #FF0000; font-weight: bold;">&lt;&gt;</span> <span style="color: #FF0000; font-weight: bold;">-</span><span style="color: #AC00A9; font-style: italic; font-weight: bold;">1</span> <span style="color: #0000FF; font-weight: bold;">Then</span>
		<span style="font-style: italic; color: #009933;">; runter</span>
		<span style="color: #0000FF; font-weight: bold;">if</span> <span style="font-weight: bold; color: #AA0000;">$newLevel</span> <span style="color: #FF0000; font-weight: bold;">&gt;</span> <span style="font-weight: bold; color: #AA0000;">$currLevel</span> <span style="color: #0000FF; font-weight: bold;">Then</span>
			<span style="font-weight: bold; color: #AA0000;">$output</span> <span style="color: #FF0000; font-weight: bold;">=</span> <span style="font-weight: bold; color: #AA0000;">$output</span> <span style="color: #FF0000; font-weight: bold;">&amp;</span> <span style="font-weight: bold; color: #9977BB;">&quot;\begin{enumerate}&quot;</span> <span style="color: #FF0000; font-weight: bold;">&amp;</span> <span style="color: #800000; font-weight: bold;"><span style="font-weight: bold; color: #AA0000;">@CRLF</span></span>
		<span style="color: #0000FF; font-weight: bold;">EndIf</span>
		<span style="font-style: italic; color: #009933;">; (u.U. mehrfach!) hoch</span>
		<span style="color: #0000FF; font-weight: bold;">while</span> <span style="font-weight: bold; color: #AA0000;">$newLevel</span> <span style="color: #FF0000; font-weight: bold;">&lt;</span> <span style="font-weight: bold; color: #AA0000;">$currLevel</span>
			<span style="font-weight: bold; color: #AA0000;">$output</span> <span style="color: #FF0000; font-weight: bold;">=</span> <span style="font-weight: bold; color: #AA0000;">$output</span> <span style="color: #FF0000; font-weight: bold;">&amp;</span> <span style="font-weight: bold; color: #9977BB;">&quot;\end{enumerate}&quot;</span> <span style="color: #FF0000; font-weight: bold;">&amp;</span> <span style="color: #800000; font-weight: bold;"><span style="font-weight: bold; color: #AA0000;">@CRLF</span></span>
			<span style="font-weight: bold; color: #AA0000;">$currLevel</span> <span style="color: #FF0000; font-weight: bold;">-=</span> <span style="color: #AC00A9; font-style: italic; font-weight: bold;">1</span>
		<span style="color: #0000FF; font-weight: bold;">WEnd</span>
&nbsp;
		<span style="font-weight: bold; color: #AA0000;">$currLevel</span> <span style="color: #FF0000; font-weight: bold;">=</span> <span style="font-weight: bold; color: #AA0000;">$newLevel</span>
	<span style="color: #0000FF; font-weight: bold;">EndIf</span>
&nbsp;
	<span style="color: #0000FF; font-weight: bold;">If</span> <span style="color: #000080; font-style: italic; font-weight: bold;">StringRegExp</span><span style="color: #FF0000; font-weight: bold;">&#40;</span><span style="font-weight: bold; color: #AA0000;">$data</span><span style="color: #FF0000; font-weight: bold;">&#91;</span><span style="font-weight: bold; color: #AA0000;">$i</span><span style="color: #FF0000; font-weight: bold;">&#93;</span><span style="color: #FF0000; font-weight: bold;">,</span> <span style="font-weight: bold; color: #9977BB;">&quot;^\s*$&quot;</span><span style="color: #FF0000; font-weight: bold;">,</span> <span style="color: #AC00A9; font-style: italic; font-weight: bold;">0</span><span style="color: #FF0000; font-weight: bold;">&#41;</span> <span style="color: #FF0000; font-weight: bold;">=</span> <span style="color: #AC00A9; font-style: italic; font-weight: bold;">0</span> <span style="color: #0000FF; font-weight: bold;">Then</span>
		<span style="color: #0000FF; font-weight: bold;">if</span> <span style="font-weight: bold; color: #AA0000;">$levels</span><span style="color: #FF0000; font-weight: bold;">&#91;</span><span style="font-weight: bold; color: #AA0000;">$i</span><span style="color: #FF0000; font-weight: bold;">&#93;</span> <span style="color: #FF0000; font-weight: bold;">=</span> <span style="color: #AC00A9; font-style: italic; font-weight: bold;">0</span> <span style="color: #0000FF; font-weight: bold;">Then</span>
			<span style="font-weight: bold; color: #AA0000;">$output</span> <span style="color: #FF0000; font-weight: bold;">=</span> <span style="font-weight: bold; color: #AA0000;">$output</span> <span style="color: #FF0000; font-weight: bold;">&amp;</span> <span style="font-weight: bold; color: #9977BB;">&quot;\item \hl{&quot;</span> <span style="color: #FF0000; font-weight: bold;">&amp;</span> <span style="font-weight: bold; color: #AA0000;">$data</span><span style="color: #FF0000; font-weight: bold;">&#91;</span><span style="font-weight: bold; color: #AA0000;">$i</span><span style="color: #FF0000; font-weight: bold;">&#93;</span> <span style="color: #FF0000; font-weight: bold;">&amp;</span> <span style="font-weight: bold; color: #9977BB;">&quot;}&quot;</span> <span style="color: #FF0000; font-weight: bold;">&amp;</span> <span style="color: #800000; font-weight: bold;"><span style="font-weight: bold; color: #AA0000;">@CRLF</span></span>
		<span style="color: #0000FF; font-weight: bold;">Else</span>
			<span style="font-weight: bold; color: #AA0000;">$output</span> <span style="color: #FF0000; font-weight: bold;">=</span> <span style="font-weight: bold; color: #AA0000;">$output</span> <span style="color: #FF0000; font-weight: bold;">&amp;</span> <span style="font-weight: bold; color: #9977BB;">&quot;\item &quot;</span> <span style="color: #FF0000; font-weight: bold;">&amp;</span> <span style="font-weight: bold; color: #AA0000;">$data</span><span style="color: #FF0000; font-weight: bold;">&#91;</span><span style="font-weight: bold; color: #AA0000;">$i</span><span style="color: #FF0000; font-weight: bold;">&#93;</span> <span style="color: #FF0000; font-weight: bold;">&amp;</span> <span style="color: #800000; font-weight: bold;"><span style="font-weight: bold; color: #AA0000;">@CRLF</span></span>
		<span style="color: #0000FF; font-weight: bold;">EndIf</span>
	<span style="color: #0000FF; font-weight: bold;">else</span>
		<span style="font-weight: bold; color: #AA0000;">$output</span> <span style="color: #FF0000; font-weight: bold;">=</span> <span style="font-weight: bold; color: #AA0000;">$output</span> <span style="color: #FF0000; font-weight: bold;">&amp;</span> <span style="color: #800000; font-weight: bold;"><span style="font-weight: bold; color: #AA0000;">@CRLF</span></span>
	<span style="color: #0000FF; font-weight: bold;">EndIf</span>
<span style="color: #0000FF; font-weight: bold;">Next</span>
<span style="font-weight: bold; color: #AA0000;">$output</span> <span style="color: #FF0000; font-weight: bold;">&amp;=</span> <span style="font-weight: bold; color: #9977BB;">&quot;\end{enumerate}&quot;</span>
&nbsp;
<span style="font-style: italic; color: #009933;">; verschönern</span>
<span style="font-weight: bold; color: #AA0000;">$output</span> <span style="color: #FF0000; font-weight: bold;">=</span> <span style="color: #000080; font-style: italic; font-weight: bold;">StringReplace</span><span style="color: #FF0000; font-weight: bold;">&#40;</span><span style="font-weight: bold; color: #AA0000;">$output</span><span style="color: #FF0000; font-weight: bold;">,</span> <span style="color: #800000; font-weight: bold;"><span style="font-weight: bold; color: #AA0000;">@CRLF</span></span> <span style="color: #FF0000; font-weight: bold;">&amp;</span> <span style="font-weight: bold; color: #9977BB;">&quot;\end{enumerate}&quot;</span><span style="color: #FF0000; font-weight: bold;">,</span> <span style="font-weight: bold; color: #9977BB;">&quot;\end{enumerate}&quot;</span> <span style="color: #FF0000; font-weight: bold;">&amp;</span> <span style="color: #800000; font-weight: bold;"><span style="font-weight: bold; color: #AA0000;">@CRLF</span></span><span style="color: #FF0000; font-weight: bold;">&#41;</span>
&nbsp;
<span style="font-style: italic; color: #009933;">; schreiben</span>
<span style="font-weight: bold; color: #AA0000;">$fhndl</span> <span style="color: #FF0000; font-weight: bold;">=</span> <span style="color: #000080; font-style: italic; font-weight: bold;">FileOpen</span><span style="color: #FF0000; font-weight: bold;">&#40;</span><span style="color: #800000; font-weight: bold;"><span style="font-weight: bold; color: #AA0000;">@ScriptDir</span></span> <span style="color: #FF0000; font-weight: bold;">&amp;</span> <span style="font-weight: bold; color: #9977BB;">&quot;\output.txt&quot;</span><span style="color: #FF0000; font-weight: bold;">,</span> <span style="color: #AC00A9; font-style: italic; font-weight: bold;">2</span><span style="color: #FF0000; font-weight: bold;">&#41;</span>
<span style="color: #000080; font-style: italic; font-weight: bold;">FileWrite</span><span style="color: #FF0000; font-weight: bold;">&#40;</span><span style="font-weight: bold; color: #AA0000;">$fhndl</span><span style="color: #FF0000; font-weight: bold;">,</span> <span style="font-weight: bold; color: #AA0000;">$output</span><span style="color: #FF0000; font-weight: bold;">&#41;</span>
<span style="color: #000080; font-style: italic; font-weight: bold;">FileClose</span><span style="color: #FF0000; font-weight: bold;">&#40;</span><span style="font-weight: bold; color: #AA0000;">$fhndl</span><span style="color: #FF0000; font-weight: bold;">&#41;</span></pre></div></div>

<p>Das Skript erwartet eine input.txt in seinem Verzeichnis und schmeißt den LaTeX-Schnipsel in der Datei  output.txt raus.<br />
Die regulären Ausdrücke zur Erkennung der Aufzählungszeichen lassen sich oben anpassen.</p>
<p>Der Code steht unter der <a href="http://www.gnu.org/licenses/gpl-3.0.html">GPLv3</a>-Lizenz.</p>
<p>Viel Spaß damit,<br />
Johannes</p>
]]></content:encoded>
			<wfw:commentRss>http://web.slzm.de/blog/latex/aufzahlungen-von-wordhtml-nach-latex-konvertieren/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>AutoIt-Buch, Episode II</title>
		<link>http://web.slzm.de/blog/latex/autoit-buch-episode-ii/</link>
		<comments>http://web.slzm.de/blog/latex/autoit-buch-episode-ii/#comments</comments>
		<pubDate>Sat, 11 Jul 2009 16:36:01 +0000</pubDate>
		<dc:creator>Johannes</dc:creator>
				<category><![CDATA[AutoIt]]></category>
		<category><![CDATA[LaTeX]]></category>
		<category><![CDATA[Programmieren]]></category>
		<category><![CDATA[AutoIt leicht gemacht]]></category>
		<category><![CDATA[Buch]]></category>
		<category><![CDATA[free]]></category>
		<category><![CDATA[kostenlos]]></category>

		<guid isPermaLink="false">http://web.slzm.de/blog/?p=118</guid>
		<description><![CDATA[Hallo, UPDATE: Neue Version Vor allem dank der tatkräftigen Unterstützung von Rasta gibt es eine neue Version des Buches über AutoIt. Vielen herzlichen Dank für das ausführliche und sehr fundierte Lektorat. Weiterer Dank geht an bernd670 für Hinweise zur Verbesserung. &#8230; <a href="http://web.slzm.de/blog/latex/autoit-buch-episode-ii/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Hallo,</p>
<p><strong>UPDATE:</strong> <a href="http://web.slzm.de/blog/?p=201">Neue Version</a></p>
<p>Vor allem dank der tatkräftigen Unterstützung von Rasta gibt es eine neue Version des <a title="Erste Version des Buches" href="http://web.slzm.de/blog/programmieren/autoit-leicht-gemacht/" target="_self">Buches über AutoIt</a>. Vielen herzlichen Dank für das ausführliche und sehr fundierte Lektorat. Weiterer Dank geht an bernd670 für Hinweise zur Verbesserung.</p>
<p><span id="more-118"></span>In der neuen Version gibt es neben der Korrektur von viel zu zahlreichen Rechtschreib-, Komma- und Formulierungsfehlern vor allem weit schönere Tabellen und Quellcodelistings. Die Tabellen sind jetzt schön alternierend gefärbt, die Listings farblich deutlich an SciTE angenähert. Wer mir sagen kann, wie ich die Variablen ($xyz) erfassen kann, bekommt eine Erwähnung im Buch <img src='http://web.slzm.de/blog/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> .</p>

<a href='http://web.slzm.de/blog/latex/autoit-buch-episode-ii/attachment/titelseite/' title='Titelseite'><img width="150" height="150" src="http://web.slzm.de/blog/wp-content/uploads/titelseite-150x150.png" class="attachment-thumbnail" alt="Titelseite" title="Titelseite" /></a>
<a href='http://web.slzm.de/blog/latex/autoit-buch-episode-ii/attachment/listings/' title='Listings'><img width="150" height="150" src="http://web.slzm.de/blog/wp-content/uploads/listings-150x150.png" class="attachment-thumbnail" alt="Listings" title="Listings" /></a>

<p>Gun-Food hat in einem Kommentar zur ersten Veröffentlichung geschrieben, er fände die Titelseite des &#8220;Gelben Buches&#8221; nicht so schön. Daher rufe ich an dieser Stelle einen Wettbewerb aus, in dem eine neue Titelseite gekürt werden soll. Auch hierfür gibt es eine Erwähnung im Buch. Die Graphik im Format DIN-A4 soll (mindestens) den Titel (AutoIt leicht gemacht), eine Reminiszenz an AutoIt und meinen Namen enthalten. Die Datei muss unter einer passenden CC-Lizenz stehen und als Quelldatei (Ebenen mit änderbarem Text) zur Verfügung gestellt werden.</p>
<p>Die Lizenz des Buches bleibt unverändert (siehe auch im PDF selbst).</p>
<p><strong>Download:</strong> <a href="http://web.slzm.de/blog/wp-content/uploads/AutoIt_leicht_gemacht_2009-07-11.pdf"> AutoIt leicht gemacht &#8211; 11. Juli 2009</a></p>
<p>Viel Erfolg damit,<br />
<em>Johannes</em></p>
]]></content:encoded>
			<wfw:commentRss>http://web.slzm.de/blog/latex/autoit-buch-episode-ii/feed/</wfw:commentRss>
		<slash:comments>13</slash:comments>
		</item>
		<item>
		<title>Backupskript für Ubuntu mit rsnapshot</title>
		<link>http://web.slzm.de/blog/linux/backupskript-fuer-ubuntu-mit-rsnapshot/</link>
		<comments>http://web.slzm.de/blog/linux/backupskript-fuer-ubuntu-mit-rsnapshot/#comments</comments>
		<pubDate>Sun, 21 Jun 2009 19:41:09 +0000</pubDate>
		<dc:creator>Johannes</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Programmieren]]></category>
		<category><![CDATA[Ubuntu]]></category>
		<category><![CDATA[automatisch]]></category>
		<category><![CDATA[Backup]]></category>
		<category><![CDATA[Bash]]></category>
		<category><![CDATA[Notfications]]></category>
		<category><![CDATA[rsnapshot]]></category>
		<category><![CDATA[Skript]]></category>

		<guid isPermaLink="false">http://web.slzm.de/blog/?p=113</guid>
		<description><![CDATA[Mein Bash-Backupskript auf Basis von rsnapshot, das auf rsync aufbaut. Features: Donnerstags weekly-Backup, am Ersten des Monats monatliches. Mit yes.png, save.png und drive.png werden die Benachrichtigungen auch schön. Die benötigen die Notifications von Ubuntu (soweit ich mich erinnere seit 9.04 &#8230; <a href="http://web.slzm.de/blog/linux/backupskript-fuer-ubuntu-mit-rsnapshot/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Mein Bash-Backupskript auf Basis von rsnapshot, das auf rsync aufbaut.<br />
Features: Donnerstags weekly-Backup, am Ersten des Monats monatliches.<br />
Mit yes.png, save.png und drive.png werden die Benachrichtigungen auch schön. Die benötigen die Notifications von Ubuntu (soweit ich mich erinnere seit 9.04 dabei). Die Zeilen kann man auskommentieren und damit dafür sorgen, dass auch andere Linuxdistributionen unterstützt werden.<br />
Lizenz: GPLv3<br />
Viel Spaß damit!</p>
<p>Code:<br />
<span id="more-113"></span></p>
<pre language="bash" line="1">#!/bin/sh

# "programming bash"
SELF=$(readlink -f "$0" || echo "$0");
PROGRAM_DIR=$(dirname "$SELF");

notify-send -i "$PROGRAM_DIR/drive.png" "Backup" "Beginne Backup..."

# Paketliste
notify-send -i "$PROGRAM_DIR/save.png" "Backup-Status" "Erzeuge Paketliste"
dpkg --get-selections > ~/pakete.txt
notify-send -i "$PROGRAM_DIR/yes.png" "Backup-Status" "Paketliste erzeugt."

# monthly
day=$(date '+%d')
if [ $day == "01" ]; then
	notify-send -i "$PROGRAM_DIR/save.png" "Backup-Status" "Beginne monatliches Backup..."
   	time sudo rsnapshot monthly;
	notify-send -i "$PROGRAM_DIR/yes.png" "Backup-Status" "Monatliches Backup abgeschlossen."
fi

# weekly?
day=$(date '+%u')
if [ $day == "4" ]; then
	notify-send -i "$PROGRAM_DIR/save.png" "Backup-Status" "Beginne wöchentliches Backup..."
	time sudo rsnapshot weekly;
	notify-send -i "$PROGRAM_DIR/yes.png" "Backup-Status" "Wöchentliches Backup abgeschlossen."
fi

# daily
	notify-send -i "$PROGRAM_DIR/save.png" "Backup-Status" "Beginne tägliches Backup..."
time sudo rsnapshot daily;
notify-send -i "$PROGRAM_DIR/yes.png" "Backup-Status" "Tägliches Backup abgeschlossen."

notify-send -i "$PROGRAM_DIR/drive.png" "Backup" "Backup abgeschlossen. Sie können den Datenträger jetzt entfernen."</pre>
<p>Johannes</p>
]]></content:encoded>
			<wfw:commentRss>http://web.slzm.de/blog/linux/backupskript-fuer-ubuntu-mit-rsnapshot/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

