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 'rb-inotify' | |
BUILD='bundle exec mdpress --latex -s plexus presentation.md' | |
class WatchTask | |
def initialize(name, opts = {}) | |
Rake::Task.define_task name do | |
Array(opts[:watch]).each do |pattern| | |
notifier.watch(pattern, :modify, :create) do |event| | |
system(opts[:exec]) |
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
Java HotSpot(TM) 64-Bit Server VM warning: You have loaded library /home/arne/.rubies/jruby-1.7.3/lib/native/i386-Linux/libjffi-1.2.so which might have disabled stack guard. The VM will try to fix the stack guard now. | |
It's highly recommended that you fix the library with 'execstack -c <libfile>', or link it with '-z noexecstack'. | |
WARN: The Shoes.setup method is no longer used, you need to install gems yourself. | |
WARN: To use the 'bluecloth' gem, install it with 'gem install bluecloth --version '=2.0.6'', and put 'require "bluecloth"' at the top of your Shoes program. | |
WARN: To use the 'metaid' gem, install it with 'gem install metaid ', and put 'require "metaid"' at the top of your Shoes program. | |
LoadError: no such file to load -- bluecloth | |
require at org/jruby/RubyKernel.java:1027 | |
require at /home/arne/.rubies/jruby-1.7.3/lib/ruby/shared/rubygems/custom_require.rb:55 | |
(root) at /home/arne/.shoes/red_shoes/dist/samples/simple-rubygems.rb:10 | |
load at org/jruby/RubyKernel.java:1046 |
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
source 'https://rubygems.org' | |
gem 'hexp', path: '/home/arne/github/hexp' | |
gem 'virtus', github: 'solnic/virtus' | |
gem 'sinatra' | |
gem 'active_support' | |
gem 'debugger' |
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
class Note | |
attr_accessor :message | |
def initialize(attrs) | |
@message = attrs[:message] | |
end | |
def save | |
Note.all << self | |
end |
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
class FizzBuzz | |
def fizz | |
loop do | |
["", "", "Fizz"].each{|s| yield s} | |
end | |
end | |
def buzz | |
loop do | |
["", "", "", "", "Buzz"].each{|s| yield s} |
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
eval $s='def quine(t) ; puts "eval $s=#{t}(39.chr+$s+39.chr+%q[ ; quine])" ; end ; ' ; quine(39.chr+$s+39.chr+%q[ ; quine]) |
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
☻ npm install -g wake | |
npm http GET https://registry.npmjs.org/csso | |
npm http GET https://registry.npmjs.org/ejs | |
npm http GET https://registry.npmjs.org/mkdirp | |
npm http GET https://registry.npmjs.org/uglify-js | |
npm http 200 https://registry.npmjs.org/mkdirp | |
npm http GET https://registry.npmjs.org/mkdirp/-/mkdirp-0.3.5.tgz | |
npm http 200 https://registry.npmjs.org/ejs | |
npm http GET https://registry.npmjs.org/ejs/-/ejs-0.8.4.tgz | |
npm http 200 https://registry.npmjs.org/csso |
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
# put in /etc/init/librato.conf and start with 'sudo start librato' | |
description "collect metrics" | |
start on (local-filesystems and net-device-up IFACE!=lo) | |
respawn | |
env EMAIL=<your email> | |
env TOKEN=<your librato token> |