start new:
tmux
start new with session name:
tmux new -s myname
# Some good references are: | |
# http://russbrooks.com/2010/11/25/install-postgresql-9-on-os-x | |
# http://www.paolocorti.net/2008/01/30/installing-postgis-on-ubuntu/ | |
# http://postgis.refractions.net/documentation/manual-1.5/ch02.html#id2630392 | |
#1. Install PostgreSQL postgis and postgres | |
brew install postgis | |
initdb /usr/local/var/postgres | |
pg_ctl -D /usr/local/var/postgres -l /usr/local/var/postgres/server.log start |
#!/bin/bash -x | |
# This should be your "script/ci" checked into version control, and then wired as your sole build step in Jenkins. | |
# | |
# Simplifying Assumptions: | |
# | |
# * You build all branches | |
# * You want to deploy all branches. | |
# * You wired up an SSH key to your CI server appropriately so it can talk to your deployment target(s) via Cap |
// Sticky Nav Component | |
var Sticky = (function() { | |
'use strict'; | |
var CSS_CLASS_ACTIVE = 'is-fixed'; | |
var Sticky = { | |
element: null, | |
position: 0, | |
addEvents: function() { |
webpack --display-modules | awk '{print $3$4" "$2}' | grep -v bytes | sort -n | tail -100 |
@media (min-width:320px) { /* smartphones, portrait iPhone, portrait 480x320 phones (Android) */ } | |
@media (min-width:480px) { /* smartphones, Android phones, landscape iPhone */ } | |
@media (min-width:600px) { /* portrait tablets, portrait iPad, e-readers (Nook/Kindle), landscape 800x480 phones (Android) */ } | |
@media (min-width:801px) { /* tablet, landscape iPad, lo-res laptops ands desktops */ } | |
@media (min-width:1025px) { /* big landscape tablets, laptops, and desktops */ } | |
@media (min-width:1281px) { /* hi-res laptops and desktops */ } |
# Det måste vara en tom rad här av någon anledning :) | |
sv: | |
date: | |
formats: | |
default: "%Y-%m-%d" | |
short: "%b %d" | |
long: "%B %d, %Y" | |
day_names: [Söndag, Måndag, Tisdag, Onsdag, Torsdag, Fredag, Lördag] | |
abbr_day_names: [Sön, Mån, Tis, Ons, Tors, Fre, Lör] |
class ActiveRecord::Base | |
def can_destroy? | |
self.class.reflect_on_all_associations.all? do |assoc| | |
assoc.options[:dependent] != :restrict || (assoc.macro == :has_one && self.send(assoc.name).nil?) || (assoc.macro == :has_many && self.send(assoc.name).empty?) | |
end | |
end | |
end |
# Install rvm system-wide | |
bash -s stable < <(curl -s https://raw.github.com/wayneeseguin/rvm/master/binscripts/rvm-installer ) | |
# Update the packages | |
apt-get update | |
apt-get upgrade | |
apt-get install build-essential | |
# get the packages required by ruby | |
rvm pkg install zlib |