Skip to content

Instantly share code, notes, and snippets.

@beck
beck / jscs.json
Created March 18, 2014 18:29
yola style
{
"requireCurlyBraces": ["if", "else", "for", "while", "do", "try", "catch"],
"requireSpaceAfterKeywords": ["if", "else", "for", "while", "do", "switch", "return", "try", "catch"],
"disallowLeftStickedOperators": ["?", "+", "-", "/", "*", "=", "==", "===", "!=", "!==", ">", ">=", "<", "<="],
"disallowRightStickedOperators": ["?", "+", "/", "*", ":", "=", "==", "===", "!=", "!==", ">", ">=", "<", "<="],
"requireRightStickedOperators": ["!"],
"requireLeftStickedOperators": [","],
"disallowImplicitTypeConversion": ["string"],
"disallowKeywords": ["with"],
"disallowMultipleLineBreaks": true,
@beck
beck / dicks.rb
Last active August 29, 2015 14:00
dicks
#!/usr/bin/env ruby
#
# dicks v0.03 - Concise version thanks to a kind
# redditor (ageddyn)
#
# Brutish way to print out a bunch of ascii dongs.
# usage: 'dicks n' will print n dicks. Defaults
# to 5 dicks if no argument is called.
#
# Sperm patch coming soon.
@beck
beck / translations.djt
Last active August 29, 2015 14:19
because django's jsi18n js makes me sad
{% if LANGUAGE_CODE == 'en' %}
{% compress js inline %}
<script>
window.json_locale_data = {
"messages": {},
"locale": "en",
"lang": "en"
};
</script>
{% endcompress %}
@beck
beck / git-isort
Last active September 4, 2015 16:55
git util to isort all files with a diff
#!/bin/bash
#
# git isort - isort files with a diff
#
# to use:
# * install isort (this code uses pyenv and has isort installed in 2.7.5)
# * place this file anywhere on PATH, callable via `git isort`
#
@beck
beck / tube.py
Last active October 8, 2015 20:13
A generic testube config file
"""Configuration for testtube.
Automatically run tests when files change by running: stir
See: https://github.com/thomasw/testtube
For flake8, don't forget to install:
* flake8-quotes
"""
import unittest
from mock import patch, Mock
from django.shortcuts import render
class Dashboard(object):
"""This is the system under test."""
@classmethod
@beck
beck / awk.1
Created November 17, 2015 01:31
.de EX
.nf
.ft CW
..
.de EE
.br
.fi
.ft 1
..
awk
1
00:04:48,663 --> 00:04:50,247
ST. DAVID'S FIELD - TENNESSEE
1863
2
00:43:21,599 --> 00:43:28,271
Only a white man would make a fire
for everyone to see.
@beck
beck / bobo.md
Last active January 23, 2016 16:04
Bobo's getting started

Bobo

bobo's face

A novice guide to programming Bobo, our loveable cucumber (possibly pickled) slackbot.

Basic Shit

  • bobo is a hubot
  • bobo scripts are written in javascript
@beck
beck / coffee-log.md
Last active January 29, 2016 16:58
Coffee Log and Morning Science

Coffee Log

Morning Science.

Jan 29

Carson recommends 6%ish. Will bump the water to get full cup. This is a lighter brew, I hope to get something as good as what the barista at Lineage served me. I noted she uses a wide-mouthed up and gives the rest of the coffee in a caraffee. I wish JoeJoe would finish my chicken mug.

Questions