Skip to content

Instantly share code, notes, and snippets.

View duggiefresh's full-sized avatar

Doug Yun duggiefresh

View GitHub Profile
@duggiefresh
duggiefresh / launch.json
Created March 30, 2017 00:54
VS Code `launch.json` for ember-template-lint
{
// Use IntelliSense to learn about possible Node.js debug attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"name": "mocha",
"type": "node",
"request": "launch",
@duggiefresh
duggiefresh / weechat-config.txt
Last active December 30, 2015 20:05
Weechat config
/script install buffers.pl buffer_autoclose.py iset.pl go.py colorize_nicks.py
/key bind meta-g /go
/set weechat.bar.status.color_bg 0
/set weechat.bar.title.color_bg 0
/set weechat.color.chat_nick_colors 1,2,3,4,5,6
/set buffers.color.hotlist_message_fg 7
/set weechat.bar.buffers.position top
/set weechat.bar.buffers.items buffers
@duggiefresh
duggiefresh / ember-jsbins.md
Last active August 29, 2015 14:24
Ember JSBins
@duggiefresh
duggiefresh / gist:c9c6833927436c225e61
Created April 6, 2015 18:17
Test all the properties!
import Ember from 'ember';
import { test } from 'ember-qunit';
// var map = Ember.EnumerableUtils.map;
var forEach = Ember.EnumerableUtils.forEach;
var run = Ember.run;
function validateValues(object, propertyName, values, isTestForValid) {
var promise = null;
var validatedValues = [];
rinfo: {
response: [
{
id: "0",
correctAnswer: "checked",
correct: "false",
value: ""
},
{
id: "1",
@duggiefresh
duggiefresh / debian-ruby-install.sh
Last active December 23, 2015 05:39
This is first pass of a script to install Ruby via rbenv, Vim (optional Janus plugs), and zsh (oh-my-zsh).
#! /bin/bash
#
# This simple script will get you a pretty decent Ruby development setup
# for Debian based machines.
#
# Included are: Vim, tmux, Git, zsh, Janus*, rbenv.
#
# Use at your own risk!.. Buhaha
#
# Created by Doug Yun [email protected]
@duggiefresh
duggiefresh / .vimrc.before
Created August 29, 2013 02:59
My .vimrc.before
let mapleader = ","
let g:mapleader = ","
set encoding=utf-8
let g:airline_powerline_fonts=1
inoremap ;a <Esc>
@duggiefresh
duggiefresh / .vimrc.after
Created August 29, 2013 02:59
MY .vimrc.after
set t_Co=256
set pastetoggle=<F7>
syntax on
colorscheme jellybeans
set background=dark
highlight Normal guibg=black guifg=white
set mouse=a
set timeout timeoutlen=1000 ttimeoutlen=100
set showcmd
:nnoremap <Leader>c :set cursorline!<CR>
@duggiefresh
duggiefresh / .tmux.conf
Created August 29, 2013 02:58
My .tmux.conf
# Remap prefix to C-a
set -g prefix C-a
unbind C-b
#shorten escape time
set -sg escape-time 1
# Use 1-based indexes
set -g base-index 1
setw -g pane-base-index 1
@duggiefresh
duggiefresh / observer_pattern.rb
Created August 23, 2013 15:33
observer pattern in rails land
class EmailController < ApplicationController
def create
person.add_observer Agent.new
person.send_email 'Subject', 'Fred'
end
private
def person
@person ||= Person.new