Check and clean git stashes with dates

Posted on: Tuesday, Jun 14, 2016

When working with git stashes, your stash list may get filled with old savepoints from the past. This surely happens when you do not pop the stashes when using them. At one point, you may want to clean this list of stashes and check how old the stashes actually are to make sure they can be deleted.

You can check the dates of each stash in the list using the following command
git stash list --date=local

Do you want to try other date formats? You can see other options here.

Have a specific stash you want to view the date and other details? Use the following command, specifying the stash number between the brackets:
git show stash@{0}

Once you are sure you can remove your saved stashes, use the following command to clear all or specific stashes:

All stashes at once (make sure that you want to do this!):
git stash clear

Specific stash:
git stash drop stash@{0}

More information can be found on

Learning Rails – Routing

Posted on: Wednesday, May 21, 2014

Starting the second course, Rapid Prototyping with Ruby on Rails, over at the Tealeaf Academy, I’m starting to learn how to work with Rails.

One of the subjects in this lesson of study material is Rails’s Routing documentation.

In the Rails Routing guide the 7 different routes are explained that are automatically created when specifying a plural resource in routes.rb.

Read the rest of this entry »

Final Blackjack game

Posted on: Saturday, Mar 29, 2014

Blackjack board

The last lesson (week) of the Tealeaf Academy Ruby on Rails Online Bootcamp was to add betting and AJAXify the Blackjack game.

I’ve had the wildest ideas and grand schemes to make the Blackjack game a fun, flashing, exciting and grand game that even could compete with the Casinos.

Read the rest of this entry »

Blackjack on the web

Posted on: Monday, Mar 24, 2014

Blackjack cards and chipsIn week 3 of the Ruby on Rails online bootcamp I had to remake the Blackjack game using the web framework, Sinatra.

As this would be the third time making the Blackjack game, that game logic wasn’t that much of a problem anymore. However, getting used to Sinatra and suddenly making a web application proved to be a whole new learning experience.

Read the rest of this entry »

I’m working on the web version of the Blackjack game. This is done using the Sinatra framework for Ruby.

While running the development web server (Shotgun/Thin) and using sessions, you may get the following warning in the console:

Read the rest of this entry »

Blackjack console game (continued)

Posted on: Saturday, Mar 15, 2014

blackjack cardsIn the next week of the Ruby online bootcamp over at the Tealeaf Academy, you have to recreate the Blackjack game using  an object oriented approach. Having worked as a Java Software Engineer before, this isn’t much of a problem to me.

I’ve implemented the objects and spruced up the ASCII art even more then the previous version.

Read the rest of this entry »

Why use symbols as hash keys in Ruby?

Posted on: Wednesday, Mar 12, 2014


A lot of times people use symbols as keys in a Ruby hash. What’s the advantage over using a string?

E.g.:   hash[:name]  vs.   hash['name']


Using symbols not only saves time when doing comparisons, but also saves memory, because they are only stored once.

Symbols in Ruby are basically “immutable strings” .. that means that they can not be changed, and it implies that the same symbol when referenced many times throughout your source code, is always stored as the same entity, e.g. has the same object id.

Read the rest of this entry »

Maker’s Schedule, Manager’s Schedule

Posted on: Tuesday, Mar 11, 2014

As recommend by my TA, Chris Lee, in one of his previous live sessions, over at Tealeaf Academy, I read the article ‘Maker’s Schedule, Manager’s Schedule’ today.

I must say, it was a halleluja moment. Finally it all made sense how hard it is to concentrate on the development work now and then. As a developer you really need to be able concentrate on what you’re doing and try to ignore all of the distractions everywhere around you. Knowing how much distractions anyone has at their work nowadays, you can understand how hard this is.

Read the rest of this entry »

Blackjack console game

Posted on: Friday, Mar 7, 2014

blackjack cards

I’m attending the GoTealeaf Professional Grade Ruby on Rails Online Bootcamp. As an assignment you have to create a procedural Blackjack game that can be run in the console / terminal.

I’ve done this but I developed it a bit more then required: I created the Blackjack game with lots of ASCII art to make it fun.

Read the rest of this entry »

Pass by reference versus pass by value

Posted on: Friday, Mar 7, 2014

I’m currently studying Ruby and Rails with the Tealeaf Academy. It’s going well and it’s really fun to study Ruby. After years of Java, I feel Ruby is being a step forward.

During the study, the subject of Ruby’s passing by reference or passing by values.  (For the less-technical readers; this is the difference between passing the value of a variable to a method or passing only a reference to the value to a method. The latter enables the possibility of modifying the original variable by using the reference.)

Unfortunately, the whole subject of Ruby being either pass by reference or pass by value wasn’t clear to me. So I did some Googling to find out the answer. This confused me even more because some people are convinced it’s pass by reference and others are convinced it’s pass by value.
Having a Java background, I was convinced it’s pass by reference as it’s possible to modify the original object in a method using the method parameter as a reference.

Read the rest of this entry »

Page 1 of 212