J-_-L
index | github | twitter | irbtools | pws | rubykraut | ruby on ubuntu | zucker | euler | fresh
30.05.12 03.06.12
1 comment

Things I learned while implementing version 1.0 of pws

After releasing version 0.9 of my cli password manager, I received friendly feedback and suggestions, which encouraged me to further improve it. Here are some of my experiences implementing pws 1.0: […]

28.11.11

Why you should switch to 1.9: Three Ruby 1.8 bugs

Ruby 1.8 dies in June 2012. This post shows some small examples, why this is good ;) […]

01.11.10 19.01.12
9 comments

Tutorial: Build your own password safe with Ruby!

There are many implementations of password managers/safes out there. But lots of them are black boxes, either because they are not open source, or because they have to much features and it gets complicated to understand the source (which is most likely not written in a happy programming language). You don’t know, what really happens with your passwords. So…

Do it yourself!
Do it with Ruby!
Do it in less than 250 lines ;)
[…]

05.08.10 20.08.10
2 comments

Introducing Ruby Zucker - a new syntactical sugar gem

Zucker is a collection of lightweight scripts (cubes) that make Ruby even more beautiful: rubyzucker.info […]

14.07.10
3 comments

Become a Proc Star!

One useful (and funny) feature of Ruby is the Symbol#to_proc method that lets you write concise code like this: %w|1 2 3 4|.map(&:to_i). Almost everyone who knows this feature loves it ;). However, the use cases are pretty limited, because in most cases you need to pass parameters! […]

24.06.10 08.05.11
29 comments

The 28 Bytes of Ruby Joy!

The 28 Bytes of Ruby Joy will notably clean up your code: […]

24.10.09 18.11.09

Oh, this sweet and tasty syntactic sugar!

This article is written for people with experience in programming in general, but who are new to Ruby.
A German version is published in the offline magazine #2, a magazine by some students of TU Dresden.

The intention is to demonstrate some features of Ruby and show, what is so great about Ruby:

A clean syntax combined with the possibility to adapt the language to given requirements flexibly. […]

08.08.09 30.08.09

Converting decimal to binary integers: custom methods vs. to_i [Update]

At my last entry, a question arose about what is the most efficient way to convert integers between the bases 2 and 10: either using built-in ruby methods (and even do lightweight string-operations) or calculating it manually. I had to find out ;). So I have written a little benchmark program, which does the conversion in three different ways:

  1. using built-in to_i-magic
  2. calculating it by hand
  3. using sprintf

It stops the time each method needs to get the fastest. The result might be surprising. [Update: improved the custom methods] […]