- Event Constants
- BEM style -
BUZZ__MESSAGE_CREATED
instead ofCREATED_BUZZ_MESSAGE
- Past tense -
BUZZ__MESSAGE_LIKED
instead ofBUZZ__LIKE_MESSAGE
- When multi-step, use
_STARTED
,_FINISHED
, and_FAILED
suffixBUZZ__LOAD_CHANNEL_MESSAGES_STARTED
BUZZ__LOAD_CHANNEL_MESSAGES_FAILED
- BEM style -
BUZZ__LOAD_CHANNEL_MESSAGES_FINISHED
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function(exports) { | |
// Generated by psc version 0.8.5.0 | |
"use strict"; | |
var Prelude = PS["Prelude"]; | |
var Control_Monad_Aff = PS["Control.Monad.Aff"]; | |
var Control_Monad_Eff = PS["Control.Monad.Eff"]; | |
var Halogen = PS["Halogen"]; | |
var Halogen_Util = PS["Halogen.Util"]; | |
var Halogen_HTML_Indexed = PS["Halogen.HTML.Indexed"]; | |
var Halogen_HTML_Properties_Indexed = PS["Halogen.HTML.Properties.Indexed"]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module CsrfHelpers | |
def token | |
session[:csrf] ||= SecureRandom.hex(32) | |
end | |
def csrf_input_tag | |
%Q(<input type="hidden" name="authenticity_token" value="#{token}" />) | |
end | |
def csrf_meta_tag |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if File.exists? '.env' | |
File.readlines('.env'). | |
map{|l| l.chomp }. | |
reject{|l| l.empty?}. | |
map{|l| l.split '='}. | |
each {|k,v| ENV[k] ||= v} | |
end | |
IRB.conf[:USE_READLINE] = true | |
IRB.conf[:AUTO_INDENT] = false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
set wildignore +=*/.git/* | |
set wildignore +=*.ipc | |
set wildignore +=*.swp | |
set wildignore +=target | |
set wildignore +=project | |
set wildignore +=lib_managed | |
set wildignore +=_site | |
set wildignore +=node_modules | |
set wildignore +=cache |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Text; | |
using System.IO; | |
using System.Threading; | |
using System.Runtime.InteropServices; | |
using System.Diagnostics; | |
namespace Fleck |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
set t_Co=16 | |
call pathogen#runtime_append_all_bundles() | |
syntax on | |
"let g:solarized_termcolors=256 | |
colorscheme solarized | |
set background=dark | |
filetype plugin indent on | |
set nocompatible " We don't want vi compatibility. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env ruby | |
git_bundles = [ | |
"git://github.com/msanders/snipmate.vim.git", | |
#"git://github.com/scrooloose/nerdtree.git", | |
#"git://github.com/tpope/vim-haml.git", | |
"git://github.com/tpope/vim-markdown.git", | |
#"git://github.com/tpope/vim-rails.git", | |
#"git://github.com/tpope/vim-repeat.git", | |
#"git://github.com/tpope/vim-surround.git", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# A queue that you can pass to IO.select. | |
# | |
# NOT THREAD SAFE: Only one thread should write; only one thread should read. | |
# | |
# Purpose: | |
# Allow easy integration of data-producing threads into event loops. The | |
# queue will be readable from select's perspective as long as there are | |
# objects in the queue. | |
# | |
# Implementation: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
error do | |
exception = request.env['sinatra.error'] | |
Hoptoad::Notifier.send_error exception, params, request.env if %w(staging production).include?(ENV['RACK_ENV']) | |
erb :five_hundred | |
end |