I have pretty sucessfully taught myself Ruby on Rails from scratch with no real help from any one resource or book – in this post I will show you in some steps on how to learn the basics of Ruby on Rails, as well as some of the more detailed and difficult concepts to grasp.
In this post I will assume that you have already programmed in an interpreted or compiled language – C++, Java, Perl, Python are all perfect starts to a programming career.
Make sure you read all of this article before you begin, so you can see how your Rails skills will develop.
Start hacking
This is how all good programmers begin: with a weekend of time and an old fashioned hack-a-thon. I personally started with building a simple recipe app with collections of recipes in according to ingredients etc…
- Install Ruby, Rails and Gems and get them working
- If you’re on Windows, you need a Linux virtual machine to do your development in. You’ll have A LOT of problems with Rails’ incompatibilities with Windows. Just do it, trust me!
- Make the simple ‘Hello World’ app.
- Hack away.
It is up to you this stage however.
Buy a few decent books
It’s all good me saying “Just get stuck in”, but I did need a lot of physical textual help with my learning curve of Ruby on Rails more complex areas. Not all the books that I bought were helpful or even in date, but there was a few that I found were invaluable to my learning.
Book one: Advanced Rails Recipes
Book two: RailsSpace
Book three: Rails Recipes
Subscribe to Railscasts
Ryan Bates presents a weekly video podcast in all areas of Rails. The later episodes tend toward more advanced areas of Rails, but if you get all of the episodes, you will find it difficult to get stuck with development in Rails.
www.railscasts.com
Huzzah!
After weeks of coding, bottle upon bottle of IrnBru, and OS re-install, two network outages, lots of loud swearing, countless ganders and cplusplus.com, and some 900 lines of code later, and my C++ chatbot finally works!
Boris chatbot working
When these sweet lines were returned to the screen, I kissed it… no joke, I literally kissed my screen!
Look soon for the finished product, all in it’s open source glory.

Many rumours have been spreading the web recently about the new gPhone – just a rumour that Google could create a iPhone style smartphone, with it’s own embedded software and technology.
Google have now confirmed that they are to be making a new smartphone-like device which ‘makes it easy to search the web, wherever you are’. Executives from the multi-billion pound UK based phone operator Orange have flown to the Google-plex to attend preliminary talks in a joint venture over the new phone.
It has said that the new phone will feature all the normal feature of a modern smartphone; 3G, GPS, touchscreen, querty keypad – but also offers what the Apple iPhone cannot – to allow 3rd party apps.
The major problem will be for Google will come with identifying who will buy the phone. Will it be converted iFreaks? Converted Win Mobile customers? A huge majority of the users of Google technology only use their search. Will they see Google as a viable brand to trust enough for the average buyer to go with?
For us programmers and expert users, the Google phone will be a huge opertunity to write programs onto it’s platform which will undoubtably come fit with SDK and be open source.
Is it even out of the question for the Goole-Orange partnership to buy such technology and expertise seen in the openMoko.org project?
What ever may happen, Apple and M$ must be crapping themselves at the prospect of open source software becoming common place in the comsumer market, and Google taking another step towards world domination.
It has always been tricky to find a way to sync ipods in Linux, but I’ve found a way.
1. Get Amarok (version >= 1.4.4)
2. Make sure you have libipod installed – this allows iPod file functions.
3. Initialise all music in Amarok.
4. Initialise iPod
5. Goto ‘Playlist’ on the left menu bar
6. Under ‘Smart Play lists’ -> Collection -> All Collection.
7. Right click -> Synchronise to media device.
8. Goto ‘Media device’ on left menu bar.
9. At the bottom of the left pane under ‘Transfer Queue’ it should now read ‘All Collection’
10. Underneath the top menu bar select ‘Transfer’
Sorted!
This is the most recent C++ project that i’ve completed – got 100%! Woot!
It involved using classes and OOP to create a kinda mini-game where a set of Avatar (12) are assigned random IQs, then battle and the winner is based on probability between the two avatars.
My next project will be my end of term practical: either designing an SDL based Mastermind game clone, or an intellegent chat-bot.
Enjoy this for now though!
.tar.gz sources
Avatar C++ project source
.tar.gz binary (Win 32)
Avatar C++ project executable
.zip sources
Avatar C++ project executable (zip)
.zip binary (Win 32)
Avatar C++ project source (zip)
To use the executable, call it from the command line.
This code is released with no warranty. You can use, change and learn from my code but if you use it, please attribute the code to me, Andy Callaghan.
Recently I told you that I was scrapping Windows. Well a few weeks down the line, I had a few problems with my multi-headed setup with my graphics card – the nVidia Geforce 7600 GT.
I installed the new version of openSuse without any problems; Setting up an Apache server with php, cgi and ruby on rails all in the drop of a hat (not a fedora here, sorry Dr. AAA).
On first boot it displayed only on one of the screens, giving a dark off-centre shadow on the other screen – oh fudge I thought.
A quick look on t’internet was no good, as the hard Linux nerds told me to get down and dirty in the X11 configuration files.
Before I even thought about considering this, I checked with nVidia themselves, and they gave me the closed-source Linux drivers – which didn’t download properly: parity errors. I then added the legendarily named ‘packman’ repository to YaST2 – openSuse’s software manager.
A quick tick of a box and the nVidia drivers installed. When I rebooted, a little pop-up box came up helpfully saying, ‘Multi-head configuration found. Would you like to enable it?’. openSuse you beautie! It was as simple as that.
As a whole, Linux treats two screen setups a hell of a lot better than Windows does – it is a lot smoother in maximising windows and video across both screens, much more considered controls and configuration, and the openGL effects look mental on it!
So there you have it, openSuse, Linux and nVidia on Linux all rock as far as dual-head configs go.
Hee! look at me using big words like nigh! Well okay, not that big I guess.
I have finally decided to scrap Windows forever… kinda.
I’m going to use Open Suse Linux 10.2 for all my files, word processing, browsing and everything.
I will only use MS Win XP for programming, and web development – this is because Reading Uni will still want us to use Visual Studio as our IDE, and not Sun Studio, or anything Unix based (yet).
I’m currently installing it on my home computer that my parents use to try and hoist them away from using Windows, and I am about to install it on my new shiny university computer.
Now… do I want to set-up my computer as a file server at Uni?….
A team from the UK have proved that the Chip and Pin terminals that nearly all shops that take credit cards use in the UK, can be hacked.
In a video released to YouTube, the team insert a dummy card into the reader and start playing tetris on it. It raises lots of questions that whether a ‘tamper-proof’ chip-and-pin machine could be hacked to gather credit card numbers, and pins.
I’ve been using a little app called ImgBurn, which is an updated version of the DVDDecrypter burn engine, which hasn’t been updated for some time.
This new app works seamlessly with DVD Shrink, an app to make a backup of copy protected DVDs
Get Imgburn here
