<?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>/home/ap0calypse &#187; coding</title>
	<atom:link href="http://ap0calypse.agitatio.org/articles/category/coding/feed" rel="self" type="application/rss+xml" />
	<link>http://ap0calypse.agitatio.org</link>
	<description>yet another blog ...</description>
	<lastBuildDate>Fri, 23 Jul 2010 12:21:21 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.6</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>how to search a hash-key using regular-expressions</title>
		<link>http://ap0calypse.agitatio.org/articles/how-to-search-a-hash-key-using-regular-expressions</link>
		<comments>http://ap0calypse.agitatio.org/articles/how-to-search-a-hash-key-using-regular-expressions#comments</comments>
		<pubDate>Fri, 23 Jul 2010 12:21:21 +0000</pubDate>
		<dc:creator>ap0calypse</dc:creator>
				<category><![CDATA[amusing]]></category>
		<category><![CDATA[coding]]></category>
		<category><![CDATA[general]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[perl]]></category>

		<guid isPermaLink="false">http://ap0calypse.agitatio.org/?p=286</guid>
		<description><![CDATA[hi,
these days I was encountering a problem, when I was going through 2 veeeeeeery big hashes to find out which of them have similar keys (not really same keys, just slightly different). I thought, that the easiest way would be to go through both hashes in 2 for-loops and check them out one by one. [...]]]></description>
			<content:encoded><![CDATA[<p>hi,</p>
<p>these days I was encountering a problem, when I was going through 2 veeeeeeery big hashes to find out which of them have <em>similar</em> keys (not really same keys, just slightly different). I thought, that the easiest way would be to go through both hashes in 2 for-loops and check them out one by one. Unfortunately, this approach took about 2 minutes to go through (2 minutes seem like an eternity if you are staring at a terminal).</p>
<p>My first approach looked like this:</p>

<div class="wp_syntax"><div class="code"><pre class="ruby"><span style="color:#9966CC; font-weight:bold;">for</span> my <span style="color:#ff6633; font-weight:bold;">$a</span> <span style="color:#006600; font-weight:bold;">&#40;</span>keys <span style="color:#006600; font-weight:bold;">%</span>b<span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#006600; font-weight:bold;">&#123;</span>
    <span style="color:#9966CC; font-weight:bold;">for</span> my <span style="color:#ff6633; font-weight:bold;">$c</span> <span style="color:#006600; font-weight:bold;">&#40;</span>keys <span style="color:#006600; font-weight:bold;">%</span>d<span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#006600; font-weight:bold;">&#123;</span>
        <span style="color:#9966CC; font-weight:bold;">if</span> <span style="color:#006600; font-weight:bold;">&#40;</span>$c =~ m<span style="color:#006600; font-weight:bold;">/</span>^$a.<span style="color:#006600; font-weight:bold;">+</span>$<span style="color:#006600; font-weight:bold;">/</span><span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#006600; font-weight:bold;">&#123;</span>
            <span style="color:#CC0066; font-weight:bold;">print</span> <span style="color:#996600;">&quot;bingo!<span style="color:#000099;">\n</span>&quot;</span>;
        <span style="color:#006600; font-weight:bold;">&#125;</span>
    <span style="color:#006600; font-weight:bold;">&#125;</span>
<span style="color:#006600; font-weight:bold;">&#125;</span></pre></div></div>

<p>You see, the keys in the second hash (%d) always look like the keys in the first hash (%b) with the only difference, that they contain the key plus some other stuff. So if $a looks like &#8220;abc&#8221;, $c looks like &#8220;abc123&#8243;. Now, if you have 2 hashes with &#8211; let&#8217;s say &#8211; 5000 keys and values, you can easily calculate how long this could take&#8230;. (5000 x 5000 = 25.000.000) &#8230; as I already said: it takes FOREVER!</p>
<p>Now, after some searching around I found a very nice solution on the Linux and Unix Forums from a guy called &#8220;pludi&#8221;. He recommended a grep-approach. Here is now my remodelled version:</p>

<div class="wp_syntax"><div class="code"><pre class="ruby"><span style="color:#9966CC; font-weight:bold;">for</span> my <span style="color:#ff6633; font-weight:bold;">$a</span> <span style="color:#006600; font-weight:bold;">&#40;</span>keys <span style="color:#006600; font-weight:bold;">%</span>b<span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#006600; font-weight:bold;">&#123;</span>
    <span style="color:#9966CC; font-weight:bold;">for</span> my <span style="color:#ff6633; font-weight:bold;">$c</span> <span style="color:#006600; font-weight:bold;">&#40;</span>grep <span style="color:#006600; font-weight:bold;">&#123;</span> <span style="color:#006600; font-weight:bold;">/</span>^$a.<span style="color:#006600; font-weight:bold;">+</span>$<span style="color:#006600; font-weight:bold;">/</span> <span style="color:#006600; font-weight:bold;">&#125;</span> keys <span style="color:#006600; font-weight:bold;">%</span>d<span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#006600; font-weight:bold;">&#123;</span>
        <span style="color:#CC0066; font-weight:bold;">print</span> <span style="color:#996600;">&quot;bingo!<span style="color:#000099;">\n</span>&quot;</span>;
    <span style="color:#006600; font-weight:bold;">&#125;</span>
<span style="color:#006600; font-weight:bold;">&#125;</span></pre></div></div>

<p>Voila. Instead of taking 2 minutes, the loop now runs through in 15 seconds. <img src='http://ap0calypse.agitatio.org/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />  I love Perl <img src='http://ap0calypse.agitatio.org/wp-includes/images/smilies/icon_biggrin.gif' alt=':D' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://ap0calypse.agitatio.org/articles/how-to-search-a-hash-key-using-regular-expressions/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>android + ASE + Perl = </title>
		<link>http://ap0calypse.agitatio.org/articles/android-ase-perl</link>
		<comments>http://ap0calypse.agitatio.org/articles/android-ase-perl#comments</comments>
		<pubDate>Fri, 02 Jul 2010 12:43:57 +0000</pubDate>
		<dc:creator>ap0calypse</dc:creator>
				<category><![CDATA[amusing]]></category>
		<category><![CDATA[android]]></category>
		<category><![CDATA[coding]]></category>
		<category><![CDATA[general]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[perl]]></category>
		<category><![CDATA[ruby]]></category>

		<guid isPermaLink="false">http://ap0calypse.agitatio.org/?p=281</guid>
		<description><![CDATA[just started playing with my new motorola milestone with android 2.1. 
I had no idea how much fun it is to write perl-programs for this nice little device. I use the ASE (android scripting environment) which also supports python, lua, ruby &#8230;
You can get it on their website.
I guess I will write some programs soon [...]]]></description>
			<content:encoded><![CDATA[<p>just started playing with my new motorola milestone with android 2.1. <img src='http://ap0calypse.agitatio.org/wp-includes/images/smilies/icon_biggrin.gif' alt=':D' class='wp-smiley' /><br />
I had no idea how much fun it is to write perl-programs for this nice little device. I use the ASE (android scripting environment) which also supports python, lua, ruby &#8230;</p>
<p>You can get it on <a href="http://code.google.com/p/android-scripting/">their website</a>.</p>
<p>I guess I will write some programs soon to see what&#8217;s possible. The only thing that sucks on the milestone is, that the dollar sign is only available via touchpad. That&#8217;s REALLY annoying. :/</p>
]]></content:encoded>
			<wfw:commentRss>http://ap0calypse.agitatio.org/articles/android-ase-perl/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>oebbquery &#8211; a small train-connection-retrieval-tool :P</title>
		<link>http://ap0calypse.agitatio.org/articles/oebbquery-a-small-train-connection-retrieval-tool-p</link>
		<comments>http://ap0calypse.agitatio.org/articles/oebbquery-a-small-train-connection-retrieval-tool-p#comments</comments>
		<pubDate>Thu, 17 Jun 2010 12:46:53 +0000</pubDate>
		<dc:creator>ap0calypse</dc:creator>
				<category><![CDATA[amusing]]></category>
		<category><![CDATA[coding]]></category>
		<category><![CDATA[general]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[perl]]></category>

		<guid isPermaLink="false">http://ap0calypse.agitatio.org/?p=275</guid>
		<description><![CDATA[ok, today I finished my work at the fancy little script I mentioned yesterday. You can download it now here. Because wordpress for some reason doesn&#8217;t allow me to upload files without a filename-extension (grrr) it now has a txt-ending. please just ignore the extension &#8230;..
you call the script like this:

$ ./oebbquery &#34;Innsbruck Hbf&#34; &#34;Wörgl [...]]]></description>
			<content:encoded><![CDATA[<p>ok, today I finished my work at the fancy little script I mentioned <a href="http://ap0calypse.agitatio.org/articles/how-to-get-train-departure-information-for-your-console-p">yesterday</a>. You can download it now <a href="http://ap0calypse.agitatio.org/wp-content/uploads/2010/06/oebbquery.txt">here</a>. Because wordpress for some reason doesn&#8217;t allow me to upload files without a filename-extension (grrr) it now has a txt-ending. please just ignore the extension &#8230;..</p>
<p>you call the script like this:</p>

<div class="wp_syntax"><div class="code"><pre class="bash">$ .<span style="color: #000000; font-weight: bold;">/</span>oebbquery <span style="color: #ff0000;">&quot;Innsbruck Hbf&quot;</span> <span style="color: #ff0000;">&quot;Wörgl Hbf&quot;</span>
Connections from Innsbruck Hbf to Wörgl Hbf:
&nbsp;
Departure  Arrival  Duration  Changes  Train<span style="color: #7a0874; font-weight: bold;">&#40;</span>s<span style="color: #7a0874; font-weight: bold;">&#41;</span>
<span style="color: #000000;">15</span>:<span style="color: #000000;">13</span>      <span style="color: #000000;">15</span>:<span style="color: #000000;">59</span>     <span style="color: #000000;">0</span>:<span style="color: #000000;">46</span>     <span style="color: #000000;">0</span>        rex 
<span style="color: #000000;">15</span>:<span style="color: #000000;">28</span>      <span style="color: #000000;">16</span>:<span style="color: #000000;">24</span>     <span style="color: #000000;">0</span>:<span style="color: #000000;">56</span>     <span style="color: #000000;">0</span>        s 
<span style="color: #000000;">15</span>:<span style="color: #000000;">54</span>      <span style="color: #000000;">16</span>:<span style="color: #000000;">28</span>     <span style="color: #000000;">0</span>:<span style="color: #000000;">34</span>     <span style="color: #000000;">0</span>        oec</pre></div></div>

<p>Please be sure to use the correct names of the stations. for example: &#8220;wörgl&#8221; doesn&#8217;t work, but &#8220;Wörgl Hbf&#8221; works. You have to use the names provided by the oebb-website.</p>
<p>the output looks now like this:<br />
<img src="http://ap0calypse.agitatio.org/wp-content/uploads/2010/06/blubb.jpg" alt="blubb" title="blubb" width="448" height="499" class="alignnone size-full wp-image-278" /></p>
<p>have fun!</p>
]]></content:encoded>
			<wfw:commentRss>http://ap0calypse.agitatio.org/articles/oebbquery-a-small-train-connection-retrieval-tool-p/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>how to get train departure information for your console :P</title>
		<link>http://ap0calypse.agitatio.org/articles/how-to-get-train-departure-information-for-your-console-p</link>
		<comments>http://ap0calypse.agitatio.org/articles/how-to-get-train-departure-information-for-your-console-p#comments</comments>
		<pubDate>Wed, 16 Jun 2010 14:13:44 +0000</pubDate>
		<dc:creator>ap0calypse</dc:creator>
				<category><![CDATA[amusing]]></category>
		<category><![CDATA[coding]]></category>
		<category><![CDATA[general]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[perl]]></category>

		<guid isPermaLink="false">http://ap0calypse.agitatio.org/?p=271</guid>
		<description><![CDATA[hi guys,
I just spent 2 hours on a little project here. With this little script written in Perl by using LWP you now have the possibility to view train-connections from A to B in your terminal. You can then use this output to process it with conky or just any application you want. Here is [...]]]></description>
			<content:encoded><![CDATA[<p>hi guys,</p>
<p>I just spent 2 hours on a little project here. With this little script written in Perl by using LWP you now have the possibility to view train-connections from A to B in your terminal. You can then use this output to process it with conky or just any application you want. Here is a screenshot:</p>
<p><img src="http://ap0calypse.agitatio.org/wp-content/uploads/2010/06/trains.jpg" alt="trains" title="trains" width="491" height="610" class="alignnone size-full wp-image-272" /></p>
<p>As you can see, i used it to display it with conky by executing it once every 600 seconds.</p>
<p>As soon as I have cleaned up the code to make it easier to read, you can download it here.</p>
]]></content:encoded>
			<wfw:commentRss>http://ap0calypse.agitatio.org/articles/how-to-get-train-departure-information-for-your-console-p/feed</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Please &#8230; use Here-Documents &#8230;</title>
		<link>http://ap0calypse.agitatio.org/articles/please-use-here-documents</link>
		<comments>http://ap0calypse.agitatio.org/articles/please-use-here-documents#comments</comments>
		<pubDate>Wed, 09 Jun 2010 09:57:31 +0000</pubDate>
		<dc:creator>ap0calypse</dc:creator>
				<category><![CDATA[coding]]></category>
		<category><![CDATA[general]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[perl]]></category>
		<category><![CDATA[ruby]]></category>

		<guid isPermaLink="false">http://ap0calypse.agitatio.org/?p=268</guid>
		<description><![CDATA[I can&#8217;t tell you how often I see scripts and programs which contain a huge amount of echo, print or whatever calls to produce output. It is ok if there are one or two lines to print out, but it becomes inefficient when used explicitly. In shell-scripts and Perl for example you could use so-called [...]]]></description>
			<content:encoded><![CDATA[<p>I can&#8217;t tell you how often I see scripts and programs which contain a huge amount of echo, print or whatever calls to produce output. It is ok if there are one or two lines to print out, but it becomes inefficient when used explicitly. In shell-scripts and Perl for example you could use so-called Here-Documents. Never heard of them? Well, here some examples:</p>
<p>example: bash</p>

<div class="wp_syntax"><div class="code"><pre class="bash"><span style="color: #808080; font-style: italic;">#!/bin/bash</span>
<span style="color: #808080; font-style: italic;"># usage text</span>
usage<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #7a0874; font-weight: bold;">&#41;</span> <span style="color: #7a0874; font-weight: bold;">&#123;</span>
    <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;&quot;</span>
    <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;This is the usage of blabla&quot;</span>
    <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;Parameters:&quot;</span>
    <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot; -f ... Parameter 1 blabla&quot;</span>
    <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot; -g ... Parameter 2 blablubb&quot;</span>
    <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;&quot;</span>
<span style="color: #7a0874; font-weight: bold;">&#125;</span></pre></div></div>

<p>Well, here you can see that there are a lot of echo-calls (often there are MUCH more &#8230; :-/). Now, we learn about an exciting new way to shorten this. We use &#8220;cat&#8221;:</p>
<p>example: bash better</p>

<div class="wp_syntax"><div class="code"><pre class="bash"><span style="color: #808080; font-style: italic;">#!/bin/bash</span>
<span style="color: #808080; font-style: italic;"># usage text</span>
usage<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #7a0874; font-weight: bold;">&#41;</span> <span style="color: #7a0874; font-weight: bold;">&#123;</span>
    <span style="color: #c20cb9; font-weight: bold;">cat</span> <span style="color: #000000; font-weight: bold;">&lt;&lt;</span> EOUSAGE
&nbsp;
This is the usage of blabla
Parameters:
 -f ... Parameter <span style="color: #000000;">1</span> blabla
 -g ... Parameter <span style="color: #000000;">2</span> blablubb
&nbsp;
EOUSAGE
<span style="color: #7a0874; font-weight: bold;">&#125;</span></pre></div></div>

<p>So, instead of using tons of calls, just do it with one &#8220;cat&#8221;. Maybe it seems a bit pedantic of me, but this example makes more sense if you encounter more text (like HTML-output) which is printed out to a document with thousands of &#8220;echo&#8221;-s.</p>
<p>You can do this in Perl similarly:</p>

<div class="wp_syntax"><div class="code"><pre class="perl"><span style="color: #808080; font-style: italic;">#!/usr/bin/perl</span>
<span style="color: #808080; font-style: italic;"># usage text</span>
<span style="color: #000000; font-weight: bold;">sub</span> usage<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span> <span style="color: #66cc66;">&#123;</span>
    <span style="color: #000066;">print</span> <span style="color: #66cc66;">&lt;&lt;</span><span style="color: #ff0000;">&quot;EOUSAGE&quot;</span>;
&nbsp;
This is the usage of blabla
Parameters:
 -f ... Parameter <span style="color: #cc66cc;">1</span> blabla
 -g ... Parameter <span style="color: #cc66cc;">2</span> blablubb
&nbsp;
EOUSAGE
<span style="color: #66cc66;">&#125;</span></pre></div></div>

<p>or in Ruby:</p>

<div class="wp_syntax"><div class="code"><pre class="ruby"><span style="color:#008000; font-style:italic;">#!/usr/bin/ruby</span>
<span style="color:#008000; font-style:italic;"># usage text</span>
<span style="color:#9966CC; font-weight:bold;">def</span> usage
    <span style="color:#CC0066; font-weight:bold;">print</span> <span style="color:#006600; font-weight:bold;">&lt;&lt;</span>EOUSAGE
&nbsp;
    This is the usage of blabla
    Parameters:
     <span style="color:#006600; font-weight:bold;">-</span>f ... <span style="color:#9900CC;">Parameter</span> <span style="color:#006666;">1</span> blabla
     <span style="color:#006600; font-weight:bold;">-</span>g ... <span style="color:#9900CC;">Parameter</span> <span style="color:#006666;">2</span> blablubb
&nbsp;
EOUSAGE
<span style="color:#9966CC; font-weight:bold;">end</span></pre></div></div>

<p>I guess you can do something like that or similarly in nearly every language. So PLEASE, if you have much text to display in your scripts, use Here-Documents.</p>
]]></content:encoded>
			<wfw:commentRss>http://ap0calypse.agitatio.org/articles/please-use-here-documents/feed</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>some information about the eee-PC on current kernel</title>
		<link>http://ap0calypse.agitatio.org/articles/some-information</link>
		<comments>http://ap0calypse.agitatio.org/articles/some-information#comments</comments>
		<pubDate>Mon, 28 Sep 2009 11:05:39 +0000</pubDate>
		<dc:creator>ap0calypse</dc:creator>
				<category><![CDATA[coding]]></category>
		<category><![CDATA[general]]></category>
		<category><![CDATA[linux]]></category>

		<guid isPermaLink="false">http://ap0calypse.agitatio.org/?p=262</guid>
		<description><![CDATA[hi,
just wanted to give you a small update about how things are going with the current kernel (2.6.31.1 so far) on the 901 model from Asus.
Graphics:
The intel chipset ( Intel Corporation Mobile 945GME Express Integrated Graphics Controller ) works very well and even KMS works like expected. There were some minor issues that required to [...]]]></description>
			<content:encoded><![CDATA[<p>hi,</p>
<p>just wanted to give you a small update about how things are going with the current kernel (2.6.31.1 so far) on the 901 model from Asus.</p>
<p><strong>Graphics:</strong><br />
The intel chipset ( Intel Corporation Mobile 945GME Express Integrated Graphics Controller ) works very well and even KMS works like expected. There <a href="http://ap0calypse.agitatio.org/articles/kms-on-the-eee-done-right">were some minor issues</a> that required to build a initial ramdisk in the past, but now that&#8217;s not necessary anymore. I don&#8217;t know if that&#8217;s because of a bugfix or just some lucky configuration of my kernel. <img src='http://ap0calypse.agitatio.org/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' />  </p>
<p><strong>Wireless:</strong><br />
WiFi <a href="http://ap0calypse.agitatio.org/articles/ralink-2860-the-eeepc-and-2629">works with the rt2860 module</a> from /staging.</p>
<p><strong>Bluetooth:</strong><br />
I managed to use my cell phone as a modem device. It wasn&#8217;t very difficult. I&#8217;ll write a small article soon how to get this done. wvdial and rfcomm do the dirty work anyway &#8230;</p>
<p>I also bought a very nice little IBM thinkpad some days ago which I am currently tweaking to fit my needs. Screenshots will follow. Here is one from my eeePC:<br />
<a href="http://ap0calypse.agitatio.org/wp-content/uploads/2009/09/screen-2009-09-28.png"><img src="http://ap0calypse.agitatio.org/wp-content/uploads/2009/09/screen-2009-09-28-300x175.png" alt="" title="screen-2009-09-28" width="300" height="175" class="alignnone size-medium wp-image-263" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://ap0calypse.agitatio.org/articles/some-information/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>endorsing calcurse :)</title>
		<link>http://ap0calypse.agitatio.org/articles/endorsing-calcurse</link>
		<comments>http://ap0calypse.agitatio.org/articles/endorsing-calcurse#comments</comments>
		<pubDate>Wed, 02 Sep 2009 09:42:14 +0000</pubDate>
		<dc:creator>ap0calypse</dc:creator>
				<category><![CDATA[amusing]]></category>
		<category><![CDATA[artistic]]></category>
		<category><![CDATA[coding]]></category>
		<category><![CDATA[general]]></category>
		<category><![CDATA[linux]]></category>

		<guid isPermaLink="false">http://ap0calypse.agitatio.org/?p=249</guid>
		<description><![CDATA[Today I found a very nice ncurses-based calendar tool named calcurse. At first it is a bit hard to get used to it, but once you figured out how it works, you&#8217;ll love it.
Friends of console applications will love it anyway  . I have always been searching for a reasonable console tool for this [...]]]></description>
			<content:encoded><![CDATA[<p>Today I found a very nice ncurses-based calendar tool named calcurse. At first it is a bit hard to get used to it, but once you figured out how it works, you&#8217;ll love it.<br />
Friends of console applications will love it anyway <img src='http://ap0calypse.agitatio.org/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> . I have always been searching for a reasonable console tool for this task. Now I found one <img src='http://ap0calypse.agitatio.org/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>Here is the link to the website:<br />
<a href="http://culot.org/calcurse/">calcurse</a></p>
<p>I&#8217;m using it as my primary calendar application to get an overview of my daily tasks and events.</p>
<p>Here a screenshot of me entering my university lessons <img src='http://ap0calypse.agitatio.org/wp-includes/images/smilies/icon_razz.gif' alt=':P' class='wp-smiley' /> :<br />
<div id="attachment_251" class="wp-caption alignnone" style="width: 310px"><a href="http://ap0calypse.agitatio.org/wp-content/uploads/2009/09/calcurse.png"><img src="http://ap0calypse.agitatio.org/wp-content/uploads/2009/09/calcurse-300x166.png" alt="entering stuff in calcurse" title="calcurse" width="300" height="166" class="size-medium wp-image-251" /></a><p class="wp-caption-text">entering stuff in calcurse</p></div></p>
]]></content:encoded>
			<wfw:commentRss>http://ap0calypse.agitatio.org/articles/endorsing-calcurse/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>playing with github &#8211; everyone is invited!</title>
		<link>http://ap0calypse.agitatio.org/articles/playing-with-github-everyone-is-invited</link>
		<comments>http://ap0calypse.agitatio.org/articles/playing-with-github-everyone-is-invited#comments</comments>
		<pubDate>Thu, 27 Aug 2009 11:28:25 +0000</pubDate>
		<dc:creator>ap0calypse</dc:creator>
				<category><![CDATA[biology]]></category>
		<category><![CDATA[coding]]></category>
		<category><![CDATA[general]]></category>
		<category><![CDATA[perl]]></category>

		<guid isPermaLink="false">http://ap0calypse.agitatio.org/?p=246</guid>
		<description><![CDATA[#### UPDATE #####
To have a look at the project:
click me
###############
hi guys,
I decided to register an account on github to share some of my coding projects with the world. By now I only uploaded huntersim so far but some others will follow soon. If you want to help me by commenting or patching it, feel free [...]]]></description>
			<content:encoded><![CDATA[<p>#### UPDATE #####<br />
To have a look at the project:<br />
<a href="http://github.com/ap0calypse/huntersim/tree/master">click me</a><br />
###############</p>
<p>hi guys,</p>
<p>I decided to register an account on github to share some of my coding projects with the world. By now I only uploaded huntersim so far but some others will follow soon. If you want to help me by commenting or patching it, feel free to do so. Get an account at <a href="http://github.com">github.com</a> and tell me you account name by mail. I could then add you to the collaborators and you can submit your changes directly. If you just want to take a look or run the program you can of course just clone the repository without registration. </p>
<p>The public clone URL is: git://github.com/ap0calypse/huntersim.git</p>
<p>You can clone the repository with the following command:</p>
<p><code>git clone git://github.com/ap0calypse/huntersim.git</code></p>
<p>So, if you want to contribute to the project (or fork it, whatever) tell me your username and I add you to the collaborators. You should have some git knowledge. But don&#8217;t be scared. You can&#8217;t destroy anything <img src='http://ap0calypse.agitatio.org/wp-includes/images/smilies/icon_razz.gif' alt=':P' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://ap0calypse.agitatio.org/articles/playing-with-github-everyone-is-invited/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>huntersim 0.1 &#8211; my first simulation</title>
		<link>http://ap0calypse.agitatio.org/articles/huntersim-01-my-first-simulation</link>
		<comments>http://ap0calypse.agitatio.org/articles/huntersim-01-my-first-simulation#comments</comments>
		<pubDate>Wed, 24 Jun 2009 11:08:35 +0000</pubDate>
		<dc:creator>ap0calypse</dc:creator>
				<category><![CDATA[amusing]]></category>
		<category><![CDATA[artistic]]></category>
		<category><![CDATA[biology]]></category>
		<category><![CDATA[coding]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[perl]]></category>

		<guid isPermaLink="false">http://ap0calypse.agitatio.org/?p=229</guid>
		<description><![CDATA[hi guys,
some days ago I decided to write a little simulation in Perl. Well, &#8230; here is the result (huntersim-0.1). The package contains a README where everything should be explained.
Have FUN!
UPDATE:
Because people want to see pics:



]]></description>
			<content:encoded><![CDATA[<p>hi guys,</p>
<p>some days ago I decided to write a little simulation in Perl. Well, &#8230; here is the result (<a href="http://ap0calypse.agitatio.org/wp-content/uploads/2009/06/huntersim-01tar.gz">huntersim-0.1</a>). The package contains a README where everything should be explained.</p>
<p>Have FUN!</p>
<p>UPDATE:</p>
<p>Because people want to see pics:</p>
<p><a href="http://ap0calypse.agitatio.org/wp-content/uploads/2009/06/screen-huntersim.png"><img class="alignnone size-medium wp-image-232" title="screen-huntersim" src="http://ap0calypse.agitatio.org/wp-content/uploads/2009/06/screen-huntersim-300x164.png" alt="" width="300" height="164" /></a></p>
<p><a href="http://ap0calypse.agitatio.org/wp-content/uploads/2009/06/huntersim-01tar.gz"><br />
</a></p>
]]></content:encoded>
			<wfw:commentRss>http://ap0calypse.agitatio.org/articles/huntersim-01-my-first-simulation/feed</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>[UPDATE] helper script for changing the MAC</title>
		<link>http://ap0calypse.agitatio.org/articles/update-helper-script-for-changing-the-mac</link>
		<comments>http://ap0calypse.agitatio.org/articles/update-helper-script-for-changing-the-mac#comments</comments>
		<pubDate>Wed, 15 Apr 2009 11:52:39 +0000</pubDate>
		<dc:creator>ap0calypse</dc:creator>
				<category><![CDATA[coding]]></category>
		<category><![CDATA[general]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[perl]]></category>

		<guid isPermaLink="false">http://ap0calypse.agitatio.org/?p=201</guid>
		<description><![CDATA[UPDATE:
##############
I now rewrote the script a little bit to use a private MAC-area because of problems when generating some MAC-addresses. Please use this version if you want to use it &#8230;
##############
hi guys,
yesterday I told you how to change your MAC address. Because I&#8217;m unbelievably lazy I decided to write a little helper-script to do this [...]]]></description>
			<content:encoded><![CDATA[<p><strong>UPDATE</strong>:<br />
##############</p>
<p>I now rewrote the script a little bit to use a private MAC-area because of problems when generating some MAC-addresses. Please use this version if you want to use it &#8230;</p>
<p>##############</p>
<p>hi guys,</p>
<p>yesterday I told you how to <a href="http://ap0calypse.agitatio.org/articles/tip-of-the-day-change-your-mac-address">change your MAC address.</a> Because I&#8217;m unbelievably lazy I decided to write a little helper-script to do this automatically. This script generates a random MAC address and brings the interface up with it.</p>
<p>here it is: <a href='http://ap0calypse.agitatio.org/wp-content/uploads/2009/04/change-mac'>change-mac</a></p>

<div class="wp_syntax"><div class="code"><pre class="perl"><span style="color: #808080; font-style: italic;">#!/usr/bin/perl</span>
<span style="color: #000000; font-weight: bold;">use</span> strict;
&nbsp;
<span style="color: #808080; font-style: italic;"># name:     change-mac</span>
<span style="color: #808080; font-style: italic;"># author:   ap0calypse (ap0calypse@agitatio.org)</span>
<span style="color: #808080; font-style: italic;"># purpose:  helper script for bringing an interface down</span>
<span style="color: #808080; font-style: italic;">#           and up again with a random MAC-address</span>
<span style="color: #808080; font-style: italic;"># date:     2009-04-15</span>
&nbsp;
<span style="color: #808080; font-style: italic;"># replace this with your wlan-interface</span>
<span style="color: #b1b100;">my</span> <span style="color: #0000ff;">$interface</span> = <span style="color: #ff0000;">&quot;wlan0&quot;</span>;
&nbsp;
<span style="color: #b1b100;">my</span> <span style="color: #0000ff;">@val_mac</span> = <span style="color: #66cc66;">&#40;</span><span style="color: #cc66cc;">0</span> .. <span style="color: #cc66cc;">9</span>, <span style="color: #ff0000;">&quot;A&quot;</span> .. <span style="color: #ff0000;">&quot;F&quot;</span><span style="color: #66cc66;">&#41;</span>;
<span style="color: #b1b100;">my</span> <span style="color: #0000ff;">$rand_mac</span> = <span style="color: #ff0000;">&quot;AC:DE:48:&quot;</span>;
&nbsp;
<span style="color: #b1b100;">for</span> <span style="color: #66cc66;">&#40;</span><span style="color: #cc66cc;">1</span> .. <span style="color: #cc66cc;">6</span><span style="color: #66cc66;">&#41;</span> <span style="color: #66cc66;">&#123;</span>
    <span style="color: #0000ff;">$rand_mac</span> .= <span style="color: #0000ff;">$val_mac</span><span style="color: #66cc66;">&#91;</span><span style="color: #000066;">rand</span><span style="color: #66cc66;">&#40;</span><span style="color: #0000ff;">@val_mac</span><span style="color: #66cc66;">&#41;</span><span style="color: #66cc66;">&#93;</span>;
    <span style="color: #b1b100;">if</span> <span style="color: #66cc66;">&#40;</span> <span style="color: #66cc66;">&#40;</span><span style="color: #0000ff;">$_</span> <span style="color: #66cc66;">%</span> <span style="color: #cc66cc;">2</span> == <span style="color: #cc66cc;">0</span><span style="color: #66cc66;">&#41;</span> <span style="color: #66cc66;">&amp;&amp;</span> <span style="color: #0000ff;">$_</span> <span style="color: #66cc66;">!</span>= <span style="color: #cc66cc;">6</span><span style="color: #66cc66;">&#41;</span> <span style="color: #66cc66;">&#123;</span>
        <span style="color: #0000ff;">$rand_mac</span> .= <span style="color: #ff0000;">&quot;:&quot;</span>;
    <span style="color: #66cc66;">&#125;</span>
<span style="color: #66cc66;">&#125;</span>
&nbsp;
<span style="color: #000066;">system</span><span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">&quot;ifconfig $interface down&quot;</span><span style="color: #66cc66;">&#41;</span>;
<span style="color: #000066;">system</span><span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">&quot;ifconfig $interface hw ether $rand_mac&quot;</span><span style="color: #66cc66;">&#41;</span>;
<span style="color: #000066;">system</span><span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">&quot;ifconfig $interface up&quot;</span><span style="color: #66cc66;">&#41;</span>;</pre></div></div>

]]></content:encoded>
			<wfw:commentRss>http://ap0calypse.agitatio.org/articles/update-helper-script-for-changing-the-mac/feed</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
	</channel>
</rss>
