Skip to content

Instantly share code, notes, and snippets.

Testing statuses

Mikael Brevik mikaelbr

Testing statuses
Block or report user

Report or block mikaelbr

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile

Let's Encrypt with nginx + auto renewal

Let's Encrypt is a new, free, automated, and open Certificate Authority.

Find out more out Let's Encrypt, and how you can use in the Let's Encrypt documentation.

This file will guide you through the minimum things you need to set up Let's Encrypt on your nginx webserver.

torgeir / omniscient-with-requestAnimationFrame.js
Last active Aug 29, 2015
Testing omniscient with requestAnimationFrame.
View omniscient-with-requestAnimationFrame.js
var React = require('react'),
component = require('../'),
immstruct = require('immstruct'),
Immutable = require('immutable'),
d3 = require('d3');
var d = React.DOM;
var w = Math.max(document.documentElement.clientWidth, window.innerWidth || 0),
h = Math.max(document.documentElement.clientHeight, window.innerHeight || 0),
torgeir / playing-with-js-combinators.js
Last active May 18, 2017
Playing with js combinators.
View playing-with-js-combinators.js
var log = console.log.bind(console);
var arr = [1, 2, undefined, 3];
var unary = (v) => v;
var binary = (first, rest) => [first, rest];
log('unary', unary.apply(null, arr)); // 1
log('binary', binary.apply(null, arr)); // [1, 2]
substack / package.json
Created Dec 6, 2013
using `npm run` to build and watch with less and browserify
View package.json
"name": "my-app",
"version": "0.0.0",
"dependencies": {
"browserify": "~2.36.1",
"less": "~1.5.1"
"devDependencies": {
"watchify": "~0.4.1",
"catw": "~0.2.0"
#-*- coding: UTF-8 -*-
import os, time
import usb.core
import usb.util
import pygtk
import gtk
from sys import exit
geta6 /
Created Sep 27, 2012
response partial content in node.js
# blob : Object from MongoDB
# blob.body: Buffer
# blob.size: length of buffer, substitute for blob.body.length
# blob.type: MIME (Eg. audio/x-wav)
# req : Object from http
# res : Object from http
# _ : Object from underscore
pwenzel /
Created Jun 6, 2012
Git Log to Tab-Delimited CSV File
# Local Dates:
git log --date=local --pretty=format:"%h%x09%an%x09%ad%x09%s" > commits.local.tsv.txt
# ISO Dates:
git log --date=iso --pretty=format:"%h%x09%an%x09%ad%x09%s" > commits.iso.tsv.txt
lucasfais / gist:1207002
Created Sep 9, 2011
Sublime Text 2 - Useful Shortcuts
View gist:1207002

Sublime Text 2 – Useful Shortcuts (Mac OS X)


⌘T go to file
⌘⌃P go to project
⌘R go to methods
⌃G go to line
⌘KB toggle side bar
⌘⇧P command prompt
You can’t perform that action at this time.