http://www.amazon.com/The-Pragmatic-Programmer-Journeyman-Master/dp/020161622X
https://www.infoq.com/minibooks/domain-driven-design-quickly/
#! /usr/bin/ruby | |
# Output test results to screen statusline | |
# Author: Arafat M (http://github.com/arafatm) | |
# | |
# WARNING: This code has not been tested. Quick and dirty to see if I could | |
# get it to work | |
# | |
# Shamelessly copied code and concepts from: | |
# |
# Watch test and app directories and run tests if any files change | |
require 'colorize' | |
def watch_tests | |
watch( 'test/(.*)/(.*).rb' ) do |md| | |
puts "\n\n--------------- #{md[0]}".colorize(:cyan) | |
run_test md[0] | |
end | |
end |
Use RubyInstaller to install Ruby 2.0.0.
Make sure you select the following options during the install
Screenshot if you're not sure (https://www.dropbox.com/s/kyfosejk2fr4gdw/rubyinstaller.png)
vagrant@precise32:/vagrant$ bundle install --verbose --without production | |
Fetching from: https://rubygems.org/api/v1/dependencies | |
HTTP Redirection | |
Fetching from: https://bundler.rubygems.org/api/v1/dependencies | |
HTTP Success | |
Fetching gem metadata from https://rubygems.org/ | |
Query List: ["rails", "sqlite3", "sass-rails", "uglifier", "coffee-rails", "jquery-rails", "turbolinks", "jbuilder", "sdoc", "pg", "rails_12factor"] | |
Query Gemcutter Dependency Endpoint API: rails,sqlite3,sass-rails,uglifier,coffee-rails,jquery-rails,turbolinks,jbuilder,sdoc,pg,rails_12factor | |
Fetching from: https://rubygems.org/api/v1/dependencies?gems=rails,sqlite3,sass-rails,uglifier,coffee-rails,jquery-rails,turbolinks,jbuilder,sdoc,pg,rails_12factor | |
HTTP Redirection |
https://github.com/arafatm/dotfiles/blob/master/install/rbenv.sh
This will install rbenv, the latest stable version of ruby and postgresql
This script will take a while to run/install, so be patient
#!/usr/bin/env ruby | |
# USAGE: dnd.rb +0 0d0[+0] [0] | |
# e.g. dnd.rb +0 2d6 | |
# or dnd.rb +5 2d6+6 2 (for 2 attacks per round e.g. flurry) | |
if ARGV.length < 2 | |
puts "ARGS = attk dmg" | |
puts "e.g. +5 2d6+2" | |
exit | |
end |
arafatm@ARAFATM_WIN7 /c/home/code | |
$ ruby dnd.rb +5 1d8+4 2 | |
AC | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | | |
HIT | 0.70 | 0.65 | 0.60 | 0.55 | 0.50 | 0.45 | 0.40 | 0.35 | 0.30 | 0.25 | 0.20 | 0.15 | 0.10 | 0.05 | | |
D/R | 11.90 | 11.05 | 10.20 | 9.35 | 8.50 | 7.65 | 6.80 | 5.95 | 5.10 | 4.25 | 3.40 | 2.55 | 1.70 | 0.85 | | |
On a hit, avg dmg = 8.5 | |
arafatm@ARAFATM_WIN7 /c/home/code | |
$ ruby dnd.rb +3 1d8+4 3 |
arafatm@ARAFATM_WIN7 /c/home/code | |
$ ruby dnd.rb +5 2d6+4 | |
AC | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | | |
HIT | 0.70 | 0.65 | 0.60 | 0.55 | 0.50 | 0.45 | 0.40 | 0.35 | 0.30 | 0.25 | 0.20 | 0.15 | 0.10 | 0.05 | | |
D/R | 7.70 | 7.15 | 6.60 | 6.05 | 5.50 | 4.95 | 4.40 | 3.85 | 3.30 | 2.75 | 2.20 | 1.65 | 1.10 | 0.55 | | |
On a hit, avg dmg = 11.0 | |
arafatm@ARAFATM_WIN7 /c/home/code | |
$ ruby dnd.rb +4 2d6+7 |
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
# This configuration requires Vagrant 1.5 or newer and two plugins: | |
# | |
# vagrant plugin install vagrant-hosts ~> 2.1.4 | |
# vagrant plugin install vagrant-auto_network ~> 1.0.0 | |
# | |
# After installation, the following steps will spin up a master and agent that | |
# can communicate with each other: |