- Bundler - Bundler maintains a consistent environment for ruby applications. It tracks an application's code and the rubygems it needs to run, so that an application will always have the exact gems (and versions) that it needs to run.
- rabl - General ruby templating with json, bson, xml, plist and msgpack support
- Thin - Very fast and lightweight Ruby web server
- Unicorn - Unicorn is an HTTP server for Rack applications designed to only serve fast clients on low-latency, high-bandwidth connections and take advantage of features in Unix/Unix-like kernels.
- SimpleCov - SimpleCov is a code coverage analysis tool for Ruby 1.9.
- Zeus - Zeus preloads your Rails app so that your normal development tasks such as console, server, generate, and specs/tests take less than one second.
- [factory_girl](h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Use Gists to store code you would like to remember later on | |
console.log(window); // log the "window" object to the console |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module Excel | |
module Formulas | |
def pmt(rate, nper, pv, fv=0, type=0) | |
((-pv * pvif(rate, nper) - fv ) / ((1.0 + rate * type) * fvifa(rate, nper))) | |
end | |
def ipmt(rate, per, nper, pv, fv=0, type=0) | |
p = pmt(rate, nper, pv, fv, 0); | |
ip = -(pv * pow1p(rate, per - 1) * rate + p * pow1pm1(rate, per - 1)) | |
(type == 0) ? ip : ip / (1 + rate) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'function' | |
# A fibonacci function. | |
fib = Function.new | |
fib[0] = 0 | |
fib[1] = 1 | |
fib[Integer] = proc { |i| fib[i - 2] + fib[i - 1] } | |
p fib[0] # => 0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# After building a new Linode Ubuntu 13.04 image... | |
ssh root@linode-123 | |
# ... | |
uname -a | |
# Linux li348-235 3.12.9-x86_64-linode37 #1 SMP Mon Feb 3 10:01:02 EST 2014 x86_64 x86_64 x86_64 GNU/Linux | |
apt-get update | |
apt-get install -y linux-virtual grub-legacy-ec2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
NOKOGIRI_USE_SYSTEM_LIBRARIES=1 \ | |
gem install nokogiri -v '1.6.1' -- \ | |
--with-xml2-config=/usr/local/opt/libxml2/bin/xml2-config \ | |
--with-xslt-config=/usr/local/opt/libxslt/bin/xslt-config |
I hereby claim:
- I am murdho on github.
- I am murdho (https://keybase.io/murdho) on keybase.
- I have a public key whose fingerprint is 00F2 1B91 9FDD 9CA7 F90D 5008 A77F 6771 24C5 8921
To claim this, I am signing this object:
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Replace "#..." with something to make it return "something!" | |
# (please use Ruby 2.1 or newer) | |
something = #... | |
something.something unless something | |
# => "something!" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@trace_depth = 0 | |
@trace = TracePoint.new(:call, :return) do |tp| | |
if tp.path.include?("/murdho/Developer/APP_NAME_HERE") | |
is_a_call = tp.event == :call | |
is_a_call ? @trace_depth += 1 : @trace_depth -= 1 | |
@trace_depth = 0 if @trace_depth < 0 | |
puts [ | |
" " * @trace_depth, | |
"\e[33m", # Yellow color start |
Crystal not working in Mac OS X Mojave #6875
**jasdeepsingh ** commented on 27 Sep 2018
Solution:
export PKG_CONFIG_PATH=/usr/local/opt/openssl/lib/pkgconfig
Fish Shell: set -U -x PKG_CONFIG_PATH /usr/local/opt/openssl/lib/pkgconfig
OlderNewer