Skip to content

Instantly share code, notes, and snippets.

var course = {
name: 'JavaScript Applications',
awesome: true,
teachers: ['Assaf', 'Shane'],
students: [
{
name: 'Steve',
computer: {
OS: 'Linux',
type: 'laptop'
@otterthecat
otterthecat / Randomizer
Created February 14, 2017 02:58
For use for first homework assignment.
var hands = ['rock' , 'paper', 'scissors'];
var handOfChoice = weapons[parseInt(Math.random()*weapons.length) %3];
## GIT PROMPT DISPLAY
ZSH_THEME_GIT_PROMPT_ADDED="%{$fg[green]%} ✚"
ZSH_THEME_GIT_PROMPT_MODIFIED="%{$fg[yellow]%} ✚"
ZSH_THEME_GIT_PROMPT_DELETED="%{$fg[red]%} ✖"
ZSH_THEME_GIT_PROMPT_RENAMED="%{$fg[magenta]%} ➜"
ZSH_THEME_GIT_PROMPT_UNMERGED="%{$fg[red]%} ⇡"
ZSH_THEME_GIT_PROMPT_UNTRACKED="%{$FG[014]%} ✭"
PROMPT='$FG[008][%*]%{$reset_color%} $FG[004]%~%{$reset_color%} $FG[006]$(git_current_branch)%{$reset_color%}$(git_prompt_status)
$FG[002]❯%{$reset_color%} '
{
"ecmaFeatures": {
"arrowFunctions": true,
"blockBindings": true,
"defaultParams": true,
"destructuring": true,
node_modules/
metrics/
test/
gulp/
gulpfile.js
*.sublime-project
*.sublime-workspace
{
"bootstrapped": true,
"in_process_packages":
[
],
"installed_packages":
[
"Alignment",
"Babel",
"ColorPicker",
@otterthecat
otterthecat / tmux-tdd.sh
Last active August 29, 2015 14:14
split terminal views for vim and unit test results
#!/bin/bash
SESSION=$USER
tmux -2 new-session -d -s $SESSION
tmux new-window -t SESSION:1 -n "code"
tmux split-window -v
tmux select-pane -t 0
tmux send-keys "vim" C-m
@otterthecat
otterthecat / .vimrc
Last active August 29, 2015 14:14
vim config
set nocompatible " be iMproved, required
filetype off " required
" set the runtime path to include Vundle and initialize
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
" alternatively, pass a path where Vundle should install plugins
"call vundle#begin('~/some/path/here')
" let Vundle manage Vundle, required
@otterthecat
otterthecat / .jshintrc
Last active August 29, 2015 14:03
default jshint config
{
"camelcase": true,
"curly": true,
"eqeqeq":true,
"forin": true,
"immed": true,
"indent": 2,
"latedef": true,
"newcap": true,
"noarg": true,
@otterthecat
otterthecat / .jscsrc
Last active August 29, 2015 14:03
Config for formatting javascript via JSCS
{
"requireCurlyBraces": [
"if",
"else",
"for",
"while",
"do",
"try",
"catch",
"finally",