Skip to content

Instantly share code, notes, and snippets.

@krrg
krrg / index.js
Created July 22, 2015 17:00
.then() and .catch() semantic comparison
var when = require('when');
var B = when(777);
// Using the .catch after .then
B.then(function(result) {
throw "There was an error in our function!";
})
.catch(function(err) {
def visit_current_page_after(&block)
orig_url = page.current_url
block.call()
visit orig_url
end
*.pyc
env/*
# Modern cipher suites
ECDHE-RSA-AES128-GCM-SHA256:
ECDHE-ECDSA-AES128-GCM-SHA256:
ECDHE-RSA-AES256-GCM-SHA384:
ECDHE-ECDSA-AES256-GCM-SHA384:
ECDHE-RSA-AES128-SHA256:
ECDHE-ECDSA-AES128-SHA256:
ECDHE-RSA-AES256-SHA384:
ECDHE-ECDSA-AES256-SHA384:
@krrg
krrg / gulpfile.js
Created November 24, 2015 21:34
Reactify and Browserify and SCSS
var gulp = require('gulp')
var browserify = require('browserify');
var source = require('vinyl-source-stream');
var reactify = require('reactify');
var sass = require('gulp-sass');
gulp.task('browserify', function () {
var b = browserify();
b.transform(reactify);
b.add('./js/routes.js'); // The root file
//
# This is a temporary server to serve the static directory correctly.
# SimpleHTTPServer couldn't do regex route matching, which meant that
# some routes weren't working correctly.
require 'sinatra'
set :public_folder, File.dirname(__FILE__)
get '/favicon.ico' do
halt 404
Aaliyah
Abbie
Abby
Abigail
Ada
Adalyn
Adalynn
Addie
Addison
Addyson
@krrg
krrg / keymap.cson
Last active September 9, 2016 01:37
My atom keymap
'atom-workspace atom-text-editor:not([mini])':
'ctrl-a':'editor:move-to-first-character-of-line'
'ctrl-e':'editor:move-to-end-of-line'
'ctrl-backspace':'core:delete'
'ctrl-shift-a':'core:select-all'
// Place your key bindings in this file to overwrite the defaults
[
{
"key": "ctrl+a",
"command": "cursorHome",
"when": "editorTextFocus"
},
{
"key": "ctrl+e",
"command": "cursorEnd",