<?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>7deeds &#187; 2-deed</title>
	<atom:link href="http://blog.7deeds.com/category/2-deed/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.7deeds.com</link>
	<description>Petros Amiridis - A humble programmer's seven noteworthy actions for the community</description>
	<lastBuildDate>Mon, 31 May 2010 12:09:10 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.1</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>PAbarcode gem</title>
		<link>http://blog.7deeds.com/2009/12/30/pabarcode-gem/</link>
		<comments>http://blog.7deeds.com/2009/12/30/pabarcode-gem/#comments</comments>
		<pubDate>Wed, 30 Dec 2009 09:07:51 +0000</pubDate>
		<dc:creator>Petros</dc:creator>
				<category><![CDATA[2-deed]]></category>
		<category><![CDATA[algorithms]]></category>
		<category><![CDATA[gems]]></category>
		<category><![CDATA[ruby]]></category>

		<guid isPermaLink="false">http://blog.7deeds.com/?p=395</guid>
		<description><![CDATA[In a previous post I mentioned that I started maintaining a set of helper Ruby classes for working with barcodes. I have changed the structure of the project to make it a gem and I have published it on GemCutter.

First you need to install the gem:

sudo gem install pabarcode

then the example in the previous post [...]]]></description>
			<content:encoded><![CDATA[<p>In a <a href="http://blog.7deeds.com/2009/12/23/ruby-barcodes/">previous post</a> I mentioned that I started maintaining a set of helper Ruby classes for working with barcodes. I have changed the structure of the <a href="http://github.com/amiridis/pabarcode">project</a> to make it a gem and I have <a href="http://gemcutter.org/gems/pabarcode">published it on GemCutter</a>.</p>
<p><span id="more-395"></span></p>
<p>First you need to install the gem:</p>
<pre class="brush: bash;">
sudo gem install pabarcode
</pre>
<p>then the example in the previous post needs to change so as it uses the gem instead of the plain Ruby file:</p>
<pre class="brush: ruby;">
require &quot;rubygems&quot;
require &quot;pabarcode&quot;

include PAbarcode

file = File.open(&quot;apog.txt&quot;)

file.each do |line|
  bc = line.slice(0..11)
  bc13 = Barcode.new(bc).get_ean_13
  puts bc13 + line.slice(12..line.length)
end

file.close
</pre>
]]></content:encoded>
			<wfw:commentRss>http://blog.7deeds.com/2009/12/30/pabarcode-gem/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Ruby helper classes for barcodes</title>
		<link>http://blog.7deeds.com/2009/12/23/ruby-barcodes/</link>
		<comments>http://blog.7deeds.com/2009/12/23/ruby-barcodes/#comments</comments>
		<pubDate>Wed, 23 Dec 2009 14:06:32 +0000</pubDate>
		<dc:creator>Petros</dc:creator>
				<category><![CDATA[2-deed]]></category>
		<category><![CDATA[algorithms]]></category>
		<category><![CDATA[ruby]]></category>
		<category><![CDATA[utilities]]></category>

		<guid isPermaLink="false">http://blog.7deeds.com/?p=385</guid>
		<description><![CDATA[In my day job, I work a lot with barcodes. We develop Windows Mobile software for devices with barcode readers. From time to time, I need to do file manipulation chores. That is: colleagues give me text files that contain barcodes and ask me to transform these.

Yesterday, a colleague of mine asked me to take [...]]]></description>
			<content:encoded><![CDATA[<p>In my day job, I work a lot with barcodes. We develop Windows Mobile software for devices with barcode readers. From time to time, I need to do file manipulation chores. That is: colleagues give me text files that contain barcodes and ask me to transform these.</p>
<p><span id="more-385"></span></p>
<p>Yesterday, a colleague of mine asked me to take as input a file with 12 characters long barcodes and add a check digit assuming the barcodes are EAN13. I decided to do it and also start maintaining a set of barcode helper classes written in Ruby. I haven&#8217;t created a gem yet, cause the functionality is &#8230; lets say limited <img src='http://blog.7deeds.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> , but I plan to do so later.</p>
<p>You can go to</p>
<p><a href="http://github.com/amiridis/rbarcode">http://github.com/amiridis/rbarcode</a> </p>
<p>and just download the barcode.rb file.</p>
<p>Here is how I used the barcode.rb file in order to transform the file:</p>
<pre class="brush: ruby;">
require &quot;barcode&quot;

file = File.open(&quot;apog.txt&quot;)

file.each do |line|
  bc = line.slice(0..11)
  bc13 = Barcode.new(bc).get_ean_13
  puts bc13 + line.slice(12..line.length)
end

file.close
</pre>
<p>The file had the following format:</p>
<pre class="brush: plain;">
520532435284;1;09
520532435285;1;09
520532463580;1;09
</pre>
<p>and for the three lines above it produces:</p>
<pre class="brush: plain;">
5205324352841;1;09
5205324352858;1;09
5205324635807;1;09
</pre>
<p><strong>Update</strong>: I have changed this project to a gem. You can read about it in my <a href="http://blog.7deeds.com/2009/12/30/pabarcode-gem/">PAbarcode gem</a> post.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.7deeds.com/2009/12/23/ruby-barcodes/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Volunteering</title>
		<link>http://blog.7deeds.com/2009/09/01/volunteering/</link>
		<comments>http://blog.7deeds.com/2009/09/01/volunteering/#comments</comments>
		<pubDate>Tue, 01 Sep 2009 10:22:35 +0000</pubDate>
		<dc:creator>Petros</dc:creator>
				<category><![CDATA[2-deed]]></category>
		<category><![CDATA[communities]]></category>
		<category><![CDATA[non-profit]]></category>
		<category><![CDATA[open-source]]></category>
		<category><![CDATA[ruby-on-rails]]></category>
		<category><![CDATA[volunteering]]></category>

		<guid isPermaLink="false">http://blog.7deeds.com/?p=346</guid>
		<description><![CDATA[Volunteering to non-profit organizations or to open source software projects is my second deed (2-deed).
I started this activity in June 2009 by becoming a member of Builders, a RailsBridge project, that connects volunteers with projects for 501c3 non-profits.
So far, I am volunteering in two projects: 1) Sunset PTA and GlamourGals Foundation.
The basic reasons I do [...]]]></description>
			<content:encoded><![CDATA[<p>Volunteering to non-profit organizations or to open source software projects is my second deed (<a href="http://blog.7deeds.com/category/2-deed/">2-deed</a>).</p>
<p><a href="http://builders.railsbridge.org/volunteers/28">I started</a> this activity in June 2009 by becoming a member of <a href="http://builders.railsbridge.org/">Builders</a>, a <a href="http://railsbridge.org/">RailsBridge</a> project, that connects volunteers with projects for <a href="http://en.wikipedia.org/wiki/501(c)#501.28c.29.283.29">501c3 non-profits</a>.</p>
<p>So far, I am volunteering in two projects: 1) <a href="http://builders.railsbridge.org/projects/6">Sunset PTA</a> and <a href="http://builders.railsbridge.org/projects/5">GlamourGals Foundation</a>.</p>
<p>The basic reasons I do this are:</p>
<ul>
<li>Learn</li>
<li>Network</li>
<li>Give back</li>
</ul>
<p>I <strong>learn</strong> asking questions or watching other team members doing stuff I don&#8217;t know. I discovered this way of learning is much faster than just reading and online searching. It cannot replace these of course, but it can help in addition to these methods of learning. Sometimes, when I learn something new from a fellow team member, I feel that it would be very difficult to discover it by myself.</p>
<p>When you volunteer to various projects, it is very easy to meet people with more or less the same mentality as yours. You get the opportunity to know them, open up your mind to new ways of thinking, choose who you like better and maybe create stronger relationships that may lead to other forms of cooperation in the future. This is extremely difficult to accomplish if one is only dedicated to their daily business because they don&#8217;t have many opportunities to <strong>network</strong> with new people.</p>
<p>Years and years, I have been receiving a lot of help from the Internet community in various forms: Forums, using free open source projects, becoming better by participating to various communities, educating myself, watching the improvement of commercial products because of the pressure of open source equivalent products, and more. I <strong>give back</strong> to the community by actively contributing and this makes me feel good. It also helps sustain the community and continue growing it.</p>
<p>This is going to be my second deed and I&#8217;ll keep posting any news that fall under this category.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.7deeds.com/2009/09/01/volunteering/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
