Skip to content

Instantly share code, notes, and snippets.

View practicingruby's full-sized avatar

Gregory Brown practicingruby

View GitHub Profile
$ curl -O http://pkgs.fedoraproject.org/repo/pkgs/libyaml/yaml-0.1.6.tar.gz/5fe00cda18ca5daeb43762b80c38e06e/yaml-0.1.6.tar.gz
$ mv yaml-0.1.6.tar.gz `brew --cache libyaml`
$ brew upgrade libyaml
To begin our explorations, let's look at an example from the Internet
Relay Chat (IRC) protocol. The following string represents the
command that you'd need to send to an IRC server to post a message
to a particular channel:
```ruby
"PRIVMSG #practicing-ruby-testing :Seasons greetings to you all!\r\n"
```
Even if you've never used IRC before or looked into its implementation

To begin our explorations, let's look at an example from the Internet Relay Chat (IRC) protocol. The following string represents the command that you'd send to an IRC server to post a message to a particular channel:

"PRIVMSG #practicing-ruby-testing :Seasons greetings to you all!\r\n"

Even if you've never used IRC before or looked into its implementation

class Chainable
def initialize(target)
@target = target
end
def method_missing(*a, &b)
@target.send(*a, &b)
self
end
end
# coding: UTF-8
require_relative "lib/prawn"
address = %{
Four score and seven years ago our fathers brought forth on this continent a
new nation, conceived in liberty, and dedicated to the proposition that all
men are created equal. Now we are engaged in a great civil war, testing
whether that nation, or any nation so conceived and so dedicated, can long
endure. We are met on a great battlefield of that war. We have come to
# this code fills out a login form,
# finds and clicks a "clock in" button on the user's dashboard
# and then inspects an HTML table representing a week calendar
# view and ensures the right time shows up in the right place
scenario "clocking in" do
timestamp = Time.now.noon
day = timestamp.to_date.cwday
simulator.log_in(employee)

In order to become a permanent member of the RMU community and move on to take additional courses, each student must pass an entrance exam and then go on to successfully complete their core skills course. The entrance exam is mainly used for ensuring that the people joining the program are diligent workers who have sufficient background knowledge to do well in our core skills course. The core skills course itself though, is something I think is something genuinely unique that you can’t find anywhere outside of RMU.

Each core course starts with roughly 15 students submitting a proposal for a personal project to work on during their session. This can be anything Ruby related, but typically involves the student building an open source application or library that scratches a particular itch of theirs. This is the first learning opportunity of the course, as it filters out those who can’t think of anything to work on. There isn’t a list of suggested projects to pick from, students need to come up with an idea the

# coding: binary
class BMP
class Reader
PIXEL_ARRAY_OFFSET = 54
BITS_PER_PIXEL = 24
DIB_HEADER_SIZE = 40
def initialize(bmp_filename)
File.open(bmp_filename, "rb") do |file|
# coding: binary
class BMP
class Reader
PIXEL_ARRAY_OFFSET = 54
BITS_PER_PIXEL = 24
DIB_HEADER_SIZE = 40
def initialize(bmp_filename)
File.open(bmp_filename, "rb") do |file|