Skip to content

Instantly share code, notes, and snippets.

View torsday's full-sized avatar

Chris Torstenson torsday

View GitHub Profile

You've just been hired by a SF tech company that is looking to expand operations into new cities. Your first task: launch Salt Lake City. To launch into a new city of this size...

You need to hire

  • 1 general manager
  • 3 salespeople
  • 2 customer support agents
  • 1 office manager
@torsday
torsday / css_selector_counter.js
Created November 4, 2013 23:58
Within a chrome console, execute the script and it will return number of CSS selectors, and how that number relates to the the IE limit. Attribution: not me.
function countCSSRules() {
var results = '',
log = '';
if (!document.styleSheets) {
return;
}
for (var i = 0; i < document.styleSheets.length; i++) {
countSheet(document.styleSheets[i]);
}
function countSheet(sheet) {
@torsday
torsday / .zshrc
Created October 21, 2013 20:08
.zshrc 2013-10-21
# Path to your oh-my-zsh configuration.
ZSH=$HOME/.oh-my-zsh
# Set name of the theme to load.
# Look in ~/.oh-my-zsh/themes/
# Optionally, if you set this to "random", it'll load a random theme each
# time that oh-my-zsh is loaded.
ZSH_THEME="robbyrussell"
# Example aliases
@torsday
torsday / README.md
Created September 8, 2013 01:23
Sudoku Puzzles

Sudoku Puzzles

  • a collection of puzzles as well as ruby programs to:
    • load into string objects
  • check for redundancy
@torsday
torsday / Preferences.txt
Created September 1, 2013 18:47
Sublime Settings
{
"color_scheme": "Packages/Color Scheme - Default/Solarized (Dark).tmTheme",
"draw_white_space": "all",
"ensure_newline_at_eof_on_save": true,
"font_face": "Inconsolata",
"font_size": 15.0,
"ignored_packages":
[
"Vintage"
],
@torsday
torsday / vim.md
Created August 23, 2013 05:05
Vim #vim #references

Vim

OF NOTE

:TOhtml
@torsday
torsday / postgres.md
Created August 22, 2013 23:45
PostgreSQL #db #notes

PostgreSQL

Basics

List Databases

$ psql -l

Open up database

@torsday
torsday / function.md
Created August 22, 2013 23:27
Comparison of function syntaxes #references #ruby #js

Comparison of function syntaxes


Ruby

def my_function(var1,var2)
   value # implicit return
end
@torsday
torsday / ruby.md
Created August 22, 2013 23:23
Ruby #references

Ruby

Basics

Running a ruby file from the command line

$ ruby <filename.rb>

Function Syntax

@torsday
torsday / brew.md
Created August 22, 2013 14:25
Homebrew #brew #references

Homebrew

Basic Commands

man brew

brew info [formula]

brew missing [formula]