<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DZone Snippets: Davor's Code Snippets</title>
    <link>http://snippets.dzone.com/posts</link>
    <pubDate>Sat, 17 May 2008 05:39:11 GMT</pubDate>
    <description>DZone Snippets: Davor's Code Snippets</description>
    <item>
      <title>Multiply two values</title>
      <link>http://snippets.dzone.com/posts/show/1904</link>
      <description>This will multiply two values.&lt;br /&gt;Written in Brainfuck.&lt;br /&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;Multiply program&lt;br /&gt;Written by Davor Babic&lt;br /&gt;davorb@gmailDOTcom&lt;br /&gt;&lt;br /&gt;Multiply 6x5&lt;br /&gt;++++++[&gt;+++++&lt;-]&gt;&lt;br /&gt;&lt;/code&gt;</description>
      <pubDate>Wed, 12 Apr 2006 04:28:11 GMT</pubDate>
      <guid>http://snippets.dzone.com/posts/show/1904</guid>
      <author>davor (Davor Babic)</author>
    </item>
    <item>
      <title>Move to values</title>
      <link>http://snippets.dzone.com/posts/show/1903</link>
      <description>This code will move two values.&lt;br /&gt;Written in Brainfuck.&lt;br /&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;Move two values&lt;br /&gt;Written by Davor Babic 2006&lt;br /&gt;davorb@gmail DOT com&lt;br /&gt;&lt;br /&gt;&gt;,[&gt;+&lt;]&gt;.&lt;br /&gt;&lt;/code&gt;</description>
      <pubDate>Wed, 12 Apr 2006 04:27:18 GMT</pubDate>
      <guid>http://snippets.dzone.com/posts/show/1903</guid>
      <author>davor (Davor Babic)</author>
    </item>
    <item>
      <title>Copy a value</title>
      <link>http://snippets.dzone.com/posts/show/1902</link>
      <description>This will copy a value. Written in Brainfuck.&lt;br /&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;Simple copy routine&lt;br /&gt;Written by Davor Babic&lt;br /&gt;davorb@gmailDOTcom&lt;br /&gt;&lt;br /&gt;,[&gt;&gt;+&lt;&lt;-]&gt;&gt;[&lt;+&lt;+&gt;&gt;-]&lt;.&gt;&gt;&gt;++++++++++&lt;br /&gt;&lt;/code&gt;</description>
      <pubDate>Wed, 12 Apr 2006 04:26:25 GMT</pubDate>
      <guid>http://snippets.dzone.com/posts/show/1902</guid>
      <author>davor (Davor Babic)</author>
    </item>
    <item>
      <title>Console keyboard scheme switcher</title>
      <link>http://snippets.dzone.com/posts/show/1901</link>
      <description>Switches between us and swedish (or any other)&lt;br /&gt;keyboard-scheme in the console. Default is US.&lt;br /&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;#!/bin/sh&lt;br /&gt;# Keyboard switcher script&lt;br /&gt;# Written in 2006 by Davor Babic &lt;davorb@gmail.com&gt;&lt;br /&gt;# This software is realeased into public domain&lt;br /&gt;&lt;br /&gt;case $1 in&lt;br /&gt;sv)&lt;br /&gt;    echo "Switching to swedish keyboard layout."&lt;br /&gt;    loadkeys /usr/share/keymaps/i386/qwerty/se-latin1.kmap.gz&lt;br /&gt;    ;;&lt;br /&gt;us)&lt;br /&gt;    echo "Switching to US keyboard layout."&lt;br /&gt;    loadkeys /usr/share/keymaps/i386/qwerty/us.kmap.gz&lt;br /&gt;    ;;&lt;br /&gt;default)&lt;br /&gt;    echo "None selected. Loading US..."&lt;br /&gt;    loadkeys /usr/share/keymaps/i386/qwerty/us.kmap.gz&lt;br /&gt;    ;;&lt;br /&gt;esac&lt;br /&gt;&lt;/code&gt;</description>
      <pubDate>Wed, 12 Apr 2006 04:20:52 GMT</pubDate>
      <guid>http://snippets.dzone.com/posts/show/1901</guid>
      <author>davor (Davor Babic)</author>
    </item>
    <item>
      <title>Digg/RSS Reader</title>
      <link>http://snippets.dzone.com/posts/show/1900</link>
      <description>Grabs the RSS-feed from digg.com and reads it out&lt;br /&gt;loud using festival.&lt;br /&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;#!/bin/sh&lt;br /&gt;# Copyright (c) 2005 Davor Babic &lt;davorb@gmail.com&gt;&lt;br /&gt;# All rights reserved.&lt;br /&gt;# Usage of the works is permitted provided that this&lt;br /&gt;# instrument is retained with the works, so that any&lt;br /&gt;# entity that uses the works is notified of this&lt;br /&gt;# instrument.&lt;br /&gt;# DISCLAIMER: THE WORKS ARE WITHOUT WARRANTY.&lt;br /&gt;&lt;br /&gt;url="http://digg.com/rss/index.xml"&lt;br /&gt;&lt;br /&gt;echo "Parsing RSS..."&lt;br /&gt;curl --silent "$url" | grep -E '(title&gt;|description&gt;)' | \&lt;br /&gt;        sed -n '4,$p' | \&lt;br /&gt;	sed -e 's/&lt;title&gt;//' -e 's/&lt;\/title&gt;//' -e 's/&lt;description&gt;/  /' \&lt;br /&gt;	    -e 's/&lt;\/description&gt;//' | head -5 &gt; digg &lt;br /&gt;echo "Reading..."&lt;br /&gt;festival --tts digg&lt;br /&gt;rm -rf ./digg&lt;br /&gt;echo "Done."&lt;br /&gt;&lt;/code&gt;</description>
      <pubDate>Wed, 12 Apr 2006 04:18:53 GMT</pubDate>
      <guid>http://snippets.dzone.com/posts/show/1900</guid>
      <author>davor (Davor Babic)</author>
    </item>
  </channel>
</rss>
