Lecture 1: Introduction to Research — [📝Lecture Notebooks] [
Lecture 2: Introduction to Python — [📝Lecture Notebooks] [
Lecture 3: Introduction to NumPy — [📝Lecture Notebooks] [
Lecture 4: Introduction to pandas — [📝Lecture Notebooks] [
Lecture 5: Plotting Data — [📝Lecture Notebooks] [[
View list.md
View gist:3185447
Setup a Three Server HAPROXY/APACHE2 Setup
Ubuntu Image used in class
image: ami-2e7e8747
Notes: For Chef Clinet install use "sudo gem install chef --no-ri --no-rdoc"
Instead of knife ec2 .. use
View http_parser.rb
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 'parslet' | |
require 'pp' | |
class HTTPParser < Parslet::Parser | |
# | |
# Character Classes | |
# | |
rule(:digit) { match('[0-9]') } | |
rule(:digits) { digit.repeat(1) } | |
rule(:xdigit) { digit | match('[a-fA-F]') } |
View gist:2664048
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 'thread' | |
@value = 1 | |
@cond = ConditionVariable.new | |
@mutex = Mutex.new | |
t = Thread.new do | |
value = @value | |
@mutex.synchronize do | |
while true | |
STDOUT.puts value |
View hack.sh
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
#!/usr/bin/env sh | |
## | |
# This is script with usefull tips taken from: | |
# https://github.com/mathiasbynens/dotfiles/blob/master/.osx | |
# | |
# install it: | |
# curl -sL https://raw.github.com/gist/2108403/hack.sh | sh | |
# |
View splat.rb
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
def match(path, *rest) | |
puts path.inspect | |
puts rest.inspect | |
end | |
a=[:inspect] | |
match(*a, {:via => :get}) |
View definition.rb
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
# modify from veewee | |
require 'digest/md5' | |
CURRENT_DIR = File.dirname(__FILE__) | |
PRESEED_MD5 = "#{Digest::MD5.file("#{CURRENT_DIR}/preseed.cfg").hexdigest}" | |
Veewee::Session.declare( { | |
:boot_cmd_sequence => [ | |
"<Esc><Esc><Enter>", | |
"/install/vmlinuz ", | |
"noapic ", |
View rbenv-install-system-wide.sh
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
# Update, upgrade and install development tools: | |
apt-get update | |
apt-get -y upgrade | |
apt-get -y install build-essential | |
apt-get -y install git-core | |
# Install rbenv | |
git clone git://github.com/sstephenson/rbenv.git /usr/local/rbenv | |
# Add rbenv to the path: |
View gist:1115122
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 'autotest/growl' | |
require 'autotest/fsevent' |
View mail_queue.rb
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 MailQueue | |
extend self | |
def queue | |
:default | |
end | |
def perform(options = {}) | |
options = options.with_indifferent_access |
NewerOlder