Skip to content

Instantly share code, notes, and snippets.

Justin Bennett zephraph

Block or report user

Report or block zephraph

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
zephraph /
Last active Dec 5, 2019 — forked from schmich/
Publish a canary package on NPM
  • Update package.json, set version to a canary version, e.g. 2.0.0-canary-<PR#>, 3.1.5-canary-<PR#>, ...
  • Run npm publish --tag canary to publish the package under the next tag
  • Run npm install --save @artsy/reaction@canary to install canary package
zephraph / github-event-router.ts
Created Oct 25, 2019
A ziet now router for github webhooks
View github-event-router.ts
import { NowRequest, NowResponse } from "@now/node";
import { http, https } from "follow-redirects";
import { URL } from "url";
export = (request: NowRequest, response: NowResponse) => {
const event = request.headers["x-github-event"];
if (!event) return response.status(404).end();
const url = new URL(`https://${}/${request.url}`);
zephraph / color-test.js
Created Jul 3, 2019
Test color algorithms
View color-test.js
// uses mocha
const { rgb } = require("wcag-contrast");
const fromHex = require("@fantasy-color/from-hex").default;
const fs = require("fs");
const assert = require("assert");
const parsedColors = fs
.readFileSync(__dirname + "/../parsed-colors.txt")
zephraph / fetch-colors.js
Last active Jul 3, 2019
Github label color scrape
View fetch-colors.js
// Uses wdio to run
const fs = require("fs");
const colors = fs
const pages = => `${color.slice(1)}`);
zephraph / parse-colors.js
Last active Jul 3, 2019
Parsed GitHub label colors
View parse-colors.js
const fs = require("fs");
const fromRGB = require("@fantasy-color/from-rgb").default;
const hex = color => color.toString(16).padStart(2, "0");
const rgbToHex = rgb => {
const { red, green, blue } = fromRGB(rgb);
return `#${hex(red)}${hex(green)}${hex(blue)}`;
const colors = fs
zephraph / colors.txt
Created Jul 3, 2019
Color test range
View colors.txt
zephraph /
Last active May 15, 2019
A shell script to clean up all node_modules in projects that haven't been touched in a couple weeks.
node_modules=$(find $SEARCH_PATH -name "node_modules" -type d -prune)
View SketchSystems.spec
tabActivated -> SetTimer
tabDeactivated -> TimerPaused
timerExpired -> TimerWaitingToReset
timerReset -> TabTimerTicking
deactivateTimers -> NotStarted
tabActivated -> TabTimerTicking
View gist:56186b0460512051a1b9b38cd06c80ce
### Keybase proof
I hereby claim:
* I am zephraph on github.
* I am zephraph ( on keybase.
* I have a public key ASD1RxP1w5y9jQgHhB6PxWD5KmyzeRSyO0CG2C4gMdiAFQo
To claim this, I am signing this object:
zephraph / pre-commit
Last active Mar 11, 2018
Git hook for automatically switching between work/oss accounts depending on the directory
View pre-commit
# This file should live at ~/.git/hooks
import os
from subprocess import call
if "git/work" in cwd:
print "Using work account"
call("git config <Your name>", shell=True)
You can’t perform that action at this time.