Skip to content

Instantly share code, notes, and snippets.

View hharnisc's full-sized avatar
🏗️
Work in progress

Harrison Harnisch hharnisc

🏗️
Work in progress
View GitHub Profile
@hharnisc
hharnisc / harrison.zsh-theme
Created February 20, 2020 02:02
Minimal ZSH Theme
local resetColor="%{$reset_color%}"
local logo="%{$fg_bold[white]%}Δ$resetColor$resetColor"
local hostname=`hostname`
local dir="%{$fg_bold[white]%}%c$resetColor$resetColor"
GIT_PROMPT_PREFIX="[%{$fg_bold[white]%}"
GIT_PROMPT_SUFFIX="$resetColor]"
GIT_PROMPT_DIRTY="%{$fg_bold[red]%}"
GIT_PROMPT_CLEAN="%{$fg_bold[green]%}"
@hharnisc
hharnisc / .tmux.conf
Last active February 7, 2020 22:38
Vim + Tmux Dotfiles
set -g mouse on
# panes
set -g pane-border-style fg=colour235
set -g pane-active-border-style fg=colour15
# statusbar
set -g status-position bottom
set -g status-justify left
set -g status-style bg=colour235,fg=colour0,dim
package main
import (
"context"
"os"
"github.com/firecracker-microvm/firecracker-go-sdk"
models "github.com/firecracker-microvm/firecracker-go-sdk/client/models"
log "github.com/sirupsen/logrus"
)
func main() {
logger := log.New()
@hharnisc
hharnisc / commits_per_author.py
Last active February 13, 2018 14:59
Atomic Migration Strategy For Web Teams - Chapter 1 Graphs
import math
from datetime import datetime
import matplotlib.pyplot as plt
import numpy
num_authors = [36, 36, 31, 32, 30, 32, 44, 49, 39, 42, 39, 30, 29, 36, 31, 25, 22, 21, 20, 18, 19, 23, 16, 13, 11, 12, 12, 13, 16, 15, 11, 13, 12, 12, 11, 9]
commits = [1104, 1249, 838, 895, 912, 1070, 1667, 1102, 1358, 1563, 1251, 746, 958, 1235, 1123, 780, 636, 932, 664, 1031, 710, 829, 860, 666, 885, 1030, 485, 815, 1138, 811,1042, 1024, 1141, 1001, 1071, 835]
dates = [
@hharnisc
hharnisc / docker-compose.yml
Created October 14, 2017 16:26
Running a local S3 bucket on http://s3.local
# use "docker-compose up" to start the local s3 bucket (ctrl c to stop all services)
version: "2"
services:
s3:
image: deppy/fake-s3
ports:
- "80:4569"
expose:
- "80"
@hharnisc
hharnisc / index.js
Last active November 28, 2018 06:27
Webpack Dev Middleware (w/ Hot Module Replacement) served by `Micro`
const fs = require('fs');
const webpack = require('webpack');
const { send } = require('micro');
const config = require('./webpack.config');
const webpackMiddleware = require('webpack-dev-middleware');
const webpackHotMiddleware = require('webpack-hot-middleware');
const compiler = webpack(config);
const middleware = (next) => {
const mw = webpackMiddleware(compiler, {
#!/usr/bin/env zsh
#local return_code="%(?..%{$fg[red]%}%? ↵%{$reset_color%})"
setopt promptsubst
autoload -U add-zsh-hook
ROOT_ICON_COLOR=$fg[red]
MACHINE_NAME_COLOR=$fg[white]
CURRENT_DIRECTORY_COLOR=$fg[blue]
GIT_PROMPT_INFO=$fg[white]
import React, { PropTypes } from 'react';
import { Hoverable } from '@bufferapp/redux-hover';
const MyComponent = ({
hovered, // managed by redux-hover
onMouseEnter,
onMouseLeave,
}) =>
<div
onMouseEnter={onMouseEnter}
@hharnisc
hharnisc / Add Hyper(term)
Last active October 31, 2016 16:29
Nixos Config
nix-channel --add http://nixos.org/channels/nixpkgs-unstable
nix-channel --update
nix-channel -i hyper
module.exports = {
config: {
// default font size for all tabs
fontSize: 14,
// font family with optional fallbacks
fontFamily: 'Hack, Menlo, "DejaVu Sans Mono", "Lucida Console", monospace',
// terminal cursor background color (hex)
cursorColor: 'rgba(248,28,229,0.75)',