- Install required tools
- Latest Git Client
- gpg tools
brew install gpg
- Generate a new gpg key
brew install gpg
# Tweaked from http://tomislavsantek.iz.hr/2011/03/moving-mysql-databases-to-ramdisk-in-ubuntu-linux | |
# Log in as root | |
# Mount ramdisk folder in RAM | |
mkdir /tmp/ramdisk | |
mount -t tmpfs -o size=128M tmpfs /tmp/ramdisk/ | |
# Move MySQL data | |
mv /var/lib/mysql /tmp/ramdisk/mysql | |
ln -s /tmp/ramdisk/mysql/ /var/lib/mysql |
#!/usr/bin/env bash | |
apt-get -y update | |
apt-get -y install build-essential zlib1g-dev libssl-dev libreadline6-dev libyaml-dev git-core | |
cd /tmp | |
wget http://cache.ruby-lang.org/pub/ruby/2.0/ruby-2.0.0-p247.tar.gz | |
tar -xvzf ruby-2.0.0-p247.tar.gz | |
cd ruby-2.0.0-p247/ | |
./configure --prefix=/usr/local | |
make | |
make install |
{ | |
"AD" => ["Catalan"], | |
"AE" => ["Arabic"], | |
"AF" => ["Dari", "Pashto"], | |
"AG" => ["English"], | |
"AI" => ["English"], | |
"AL" => ["Albaniana"], | |
"AM" => ["Armenian"], | |
"AN" => ["Dutch", "Papiamento"], | |
"AR" => ["Spanish"], |
.vmm-timeline{}.vmm-timeline div *{-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;} | |
.vmm-timeline h1,.vmm-timeline h2,.vmm-timeline h3,.vmm-timeline h4,.vmm-timeline h5,.vmm-timeline h6,.vmm-timeline p,.vmm-timeline blockquote,.vmm-timeline pre,.vmm-timeline a,.vmm-timeline abbr,.vmm-timeline acronym,.vmm-timeline address,.vmm-timeline cite,.vmm-timeline code,.vmm-timeline del,.vmm-timeline dfn,.vmm-timeline em,.vmm-timeline img,.vmm-timeline q,.vmm-timeline s,.vmm-timeline samp,.vmm-timeline small,.vmm-timeline strike,.vmm-timeline strong,.vmm-timeline sub,.vmm-timeline sup,.vmm-timeline tt,.vmm-timeline var,.vmm-timeline dd,.vmm-timeline dl,.vmm-timeline dt,.vmm-timeline li,.vmm-timeline ol,.vmm-timeline ul,.vmm-timeline fieldset,.vmm-timeline form,.vmm-timeline label,.vmm-timeline legend,.vmm-timeline button,.vmm-timeline table,.vmm-timeline caption,.vmm-timeline tbody,.vmm-timeline tfoot,.vmm-timeline thead,.vmm-timeline tr,.vmm-timeline th,.vmm-timeline td,.vmm-timeline |
* B-drzewo | |
- ilość rekordów * rozmiar rekordu | |
- 100 000 000 * 10B = 1 GB | |
* index bitmapa | |
- krotnosc * (ilość / 8) = x B | |
* tabela faktów | |
- dodajemy rozmiary wszystkich atrybutów | |
- mnozymy przez ilosc wszystkich rekordow w innych tabelach |
#!/usr/bin/env bash | |
apt-get -y update | |
apt-get -y install build-essential zlib1g-dev libssl-dev libreadline6-dev libyaml-dev git-core | |
cd /tmp | |
wget http://ftp.ruby-lang.org/pub/ruby/2.0/ruby-2.0.0-p0.tar.gz | |
tar -xvzf ruby-2.0.0-p0.tar.gz | |
cd ruby-2.0.0-p0/ | |
./configure --prefix=/usr/local | |
make | |
make install |
class ActionDispatch::Routing::Mapper | |
def draw(routes_name) | |
instance_eval(File.read(Rails.root.join("config/routes/#{routes_name}.rb"))) | |
end | |
end | |
BCX::Application.routes.draw do | |
draw :api | |
draw :account | |
draw :session |
#!/usr/bin/env ruby | |
def format_commit_info timestamp, time_desc, commit_id, message, ref_name | |
[ | |
"#{timestamp.strftime("%y %b %d")}, #{timestamp.strftime("%l:%M%p").downcase}", | |
"(#{time_desc})", | |
commit_id, | |
message, | |
ref_name | |
] |