Skip to content

Instantly share code, notes, and snippets.

View zdavis's full-sized avatar

Zach Davis zdavis

View GitHub Profile
meta:
title: A Manifest Ingestion
language: language
rights: rights
description: description
creators:
- name: Rowan Ono
contributors:
- name: Ida Davis
toc:
@zdavis
zdavis / boxen-instructions.sh
Last active April 24, 2018 15:28
Getting off Boxen
# Removing Boxen
/opt/boxen/repo/script/nuke --all --force
# Removing boxen stuff from git config. Anything related to credentials or boxen likely needs to be removed.
git config --global --edit
# I had to remove homebrew git, which boxen seems to have done weird things to
brew uninstall git
# Make sure that brew works. Fix any problems. I had to uninstall a few php-related homebrew things to get doctor to pass.
// The composing class, adds drodown functionality to Navigation
export default function dropdown(Composed) {
class Dropdown extends Component {
static propTypes() {
return {
};
}
@zdavis
zdavis / sample.js
Last active September 29, 2015 20:37
redux-actions and redux-promises
# THE STORE
import promiseMiddleware from 'redux-promise';
const store = compose(
applyMiddleware(
loggerMiddleware,
promiseMiddleware,
),
reduxReactRouter({
# <mng-switcher type="checkbox" ng-model="account.is_individual" />
app.directive('mngSwitcher', [() ->
new class mngSwitcher
restrict: 'EA'
scope: {
ngModel: '='
}
@zdavis
zdavis / gist:b713e3eb96e94e90834b
Last active August 29, 2015 14:05
A simple CCS-based switcher in JS
<input type="checkbox" value="1" />
class Switcher
construct: ($el, options) ->
@$el = $el
@$switcherEl = 'some template containin markup for the switcher'
@$el.append(@$switcherEl)
@state = @$el.prop('checked')
@initEvents()
@zdavis
zdavis / tomcat7
Created June 13, 2014 18:01
tomcat7
#!/bin/bash
#
# Tomcat 7 start/stop/status script
# Forked from: https://gist.github.com/valotas/1000094
# @author: Miglen Evlogiev <bash<a href="/miglen">@miglen</a>.com>
#
# Release updates:
# Updated method for gathering pid of the current proccess
# Added usage of CATALINA_BASE
# Added coloring and additional status
@zdavis
zdavis / tomcat
Last active August 29, 2015 14:02
tomcat init.d script
#!/bin/bash
# description: Tomcat Start Stop Restart
# processname: tomcat
# chkconfig: 234 20 80
JAVA_HOME=/usr/java/jdk1.7.0_60
export JAVA_HOME
PATH=$JAVA_HOME/bin:$PATH
export PATH
CATALINA_HOME=/var/lib/tomcat7
<span class="digit-3">3</span><span class="digit-9">9</span><span> </span><span class="digit-0">0</span><span>:</span><span class="digit-1">1</span><span class="digit-6">6</span><span>:</span><span class="digit-3">3</span><span class="digit-7">7</span>