Skip to content

Instantly share code, notes, and snippets.

View novemberborn's full-sized avatar

Mark Wubben novemberborn

View GitHub Profile
@novemberborn
novemberborn / README.md
Last active January 25, 2019 12:22
AVA throwsAsync transform for jscodeshift
{
plugins: [
['./plugin', {label: 'plugin'}],
['./plugin', {label: 'plugin'}, 'named']
],
overrides: [
{
test: 'foo.js',
extends: './extends.json5',
plugins: [
@novemberborn
novemberborn / test.js.md
Created June 28, 2017 11:31
AVA snapshot report

Snapshot report for test.js

The actual snapshot is saved in test.js.snap.

Generated by AVA.

HelloWorld component

Snapshot 1

@novemberborn
novemberborn / howto.md
Last active July 31, 2016 14:29
Obtaining Let's Encrypt certificates for CloudFlare origin servers, using wilee
@novemberborn
novemberborn / howto.md
Created February 18, 2016 17:47
Creating a PKCS#12 file from a Let's Encrypt certificate
@novemberborn
novemberborn / howto.md
Created February 17, 2016 17:32
CSR with subjectAltName on OSX

Copy /System/Library/OpenSSL/openssl.cnf to a new file.

Add the following at the end:

[ req ]
req_extensions = v3_req

[ v3_req ]
# Extensions to add to a certificate request
@novemberborn
novemberborn / setup.md
Created January 7, 2016 15:05
OS X Redirect ports 80 and 443 to 8080 and 8443 respectively

Changes with .dev domains in mind.

Create /etc/pf.anchors/dev, containing:

rdr pass inet proto tcp from any to any port 80 -> 127.0.0.1 port 8080
rdr pass inet proto tcp from any to any port 443 -> 127.0.0.1 port 8443

@novemberborn
novemberborn / setup.md
Created January 7, 2016 14:28
OS X Dnsmasq setup for .dev domains

Install dnsmasq using Homebrew. Edit the dnsmasq.conf file (Homebrew will tell you where to put it) to contain:

address=/.dev/127.0.0.1
listen-address=127.0.0.1

Then make sure Dnsmasq is running (again follow Homebrew instructions).

Create the /etc/resolver/dev directory (using root) if it doesn't exist yet and create a resolver for .dev:

Keybase proof

I hereby claim:

  • I am novemberborn on github.
  • I am novemberborn (https://keybase.io/novemberborn) on keybase.
  • I have a public key ASBotTxsIgcNBdJ7414oGO7TAGHyYaUtXfNLUrR3N-maaQo

To claim this, I am signing this object:

@novemberborn
novemberborn / coverage.sh
Created November 26, 2015 12:11
Code Coverage with Babel, Istanbul & NYC
#!/bin/bash
set -e
# Shell script to compute code coverage even after the Babel transforms have
# been applied.
# Clear previous coverage.
rm -rf coverage
# Generate test coverage based on however `npm test` performs the tests.