Skip to content

Instantly share code, notes, and snippets.

View contolini's full-sized avatar
🐛
call me

Chris Contolini contolini

🐛
call me
View GitHub Profile
[{"geoid":"04000US01","name":"Alabama","B06011000.5 - Median income in the past 12 months --":null,"B06011000.5 - Median income in the past 12 months --, Error":null,"B06011001 - Total:":21830,"B06011001 - Total:, Error":266,"B06011002 - Born in state of residence":20647,"B06011002 - Born in state of residence, Error":317,"B06011003 - Born in other state of the United States":26338,"B06011003 - Born in other state of the United States, Error":531,"B06011004 - Native; born outside the United States":25825,"B06011004 - Native; born outside the United States, Error":2201,"B06011005 - Foreign born":20046,"B06011005 - Foreign born, Error":986},
{"geoid":"04000US02","name":"Alaska","B06011000.5 - Median income in the past 12 months --":null,"B06011000.5 - Median income in the past 12 months --, Error":null,"B06011001 - Total:":29932,"B06011001 - Total:, Error":1140,"B06011002 - Born in state of residence":17453,"B06011002 - Born in state of residence, Error":1099,"B06011003 - Born in other state of the United State
@contolini
contolini / git-commit-signing-fix.md
Created June 26, 2017 23:43
Fix git commit signing on Mac OS X

If you suddenly start seeing

error: cannot run gpg1: No such file or directory
error: gpg failed to sign the data
fatal: failed to write commit object

when attempting to commit changes on Mac OS X, run

@contolini
contolini / jenkins.sh
Created May 3, 2017 16:04
Running jenkins locally
#!/bin/sh
# I'm typing this from memory so YMMV
curl -o ~/Downloads/jenkins.war https://updates.jenkins-ci.org/download/war/2.46.1/jenkins.war
nohup java -jar ~/Downloads/jenkins.war --httpPort=9876
open http://localhost:9876/
@contolini
contolini / semantic-ui.html
Created March 7, 2017 06:03
Semantic UI quickstart CDN boilerplate
<!DOCTYPE html>
<html>
<head>
<!-- Standard Meta -->
<meta charset="utf-8">
<meta content="IE=edge,chrome=1" http-equiv="X-UA-Compatible">
<meta content="width=device-width, initial-scale=1.0, maximum-scale=1.0" name="viewport"><!-- Site Properties -->
<title>Semantic UI</title>
<link href="https://cdnjs.cloudflare.com/ajax/libs/semantic-ui/2.2.9/semantic.min.css" rel="stylesheet" type="text/css">
<style type="text/css">
@contolini
contolini / npm-tmp-clean.sh
Last active March 1, 2017 19:36 — forked from nemisj/npm-tmp-clean.sh
Removing npm tmp after install
#!/usr/bin/env bash
# this is pid of the bash we are in
bash_pid=$$
bash_pid=$(echo -e ${bash_pid} | tr -d '[[:space:]]');
# this is shell of the bash
shell_pid=$(ps -p ${bash_pid} -o ppid=;)
shell_pid=$(echo -e ${shell_pid} | tr -d '[[:space:]]');

Our dotfiles now include a git commit message template that encourages some best practices.

How to use our template

Download our git commit message template to your home directory:

curl https://raw.githubusercontent.com/cfpb/dotfiles/master/.gitmessage -o ~/.gitmessage
@contolini
contolini / funds.md
Last active January 29, 2024 17:14
Federal Reserve Thrift Plan Funds (as of July 2018)
@contolini
contolini / us-california.opvn
Created February 5, 2017 21:57
private internet access AES-128 openvpn config file
client
dev tun
proto udp
remote us-california.privateinternetaccess.com 1198
cipher aes-128-cbc
resolv-retry infinite
nobind
persist-key
persist-tun
tls-client
@contolini
contolini / mobile-phone-tracking-website.md
Last active April 29, 2024 14:02
How to create a simple real-time location tracking website a la https://whereis.contolini.com

The steps below require a smartphone running Android. If you're an iPhone user you'll have to find an appropriate iOS app for step #4. Maybe this?

  1. Copy this HTML file to wherever you want your page to live.
  2. Create an account at MapBox and generate an API token on your account page.
  3. Replace my API token with yours in the HTML file.
  4. Install GPS Logger for Android on your phone.
  5. Create an account at ThingSpeak and get an API key. We'll use ThingSpeak to store your GPS coordinates.
  6. Create a new ThingSpeak channel. Enable all eight fields and make the channel public. It should look like this.
  7. R
@contolini
contolini / moto-e-directions.md
Last active October 19, 2016 02:47
Installing CyanogenMod on a Moto E LTE

Below are instructions on how to flash a Moto E LTE (surnia model) with CyanogenMod, a custom Android ROM. Moto E LTEs can be obtained from MVNOs like Text Now with proprietary ROMs that prevent the device from being used with other carriers. These steps will allow the device to work with other carriers.

Note: These steps assume you're using a Mac OS X device. You'll need to adapt them if you're on Windows.


Download the following files to your desktop: