Category:: Ruby

How to Delete a File in Ruby

The following tutorial describe how to delete files and directories that you no longer need in your application. Removing single file in Ruby is simple and straightforward, with File.delete. This method Deletes the named […]

Ruby – Check whether a file or directory exists

Checking whether a file exists or not, is one of the most basic file related tasks which you will do most of the times and thankfully Ruby’s File class provides two methods called File.file?(),File.exist?() to test […]

How to iterate over a array in Ruby

The each construct provides an easy way to iterate over arrays and hash. each loop will continue until it has gone through every item in the array. We have an associative array that stores the names of fruits. We want […]

Ruby on Rails Framework basic tutorial

From Ruby on Rails developers “Ruby on Rails® is an open-source web framework that’s optimized for programmer happiness and sustainable productivity. It lets you write beautiful code by favoring convention over […]