Skip to content

Instantly share code, notes, and snippets.

View morganestes's full-sized avatar

Morgan Estes morganestes

View GitHub Profile
@morganestes
morganestes / gist:441edefc83b3c9d2f483
Created March 9, 2015 20:18
onename verification
Verifying that +morganestes is my openname (Bitcoin username). https://onename.com/morganestes
@morganestes
morganestes / node-update.sh
Last active August 29, 2015 14:17
Shell script to update node.js to latest version (OS X).
# Update to the most recent version of Node.js (and npm).
# Pass -f to force an update.
node-update() {
local force=false
local current=`node -v`
local latest=`curl -s https://nodejs.org/dist/latest/ | egrep -o 'node\-v([0-9\.]+)\.pkg' | head -n1`
while getopts ":f" opt; do
case "$opt" in
f) force=true ;;
@morganestes
morganestes / readme.md
Last active August 29, 2015 14:21
Slurp WordPress Theme and Plugins together.
  1. Clone the following repos (I keep mine in ~/Repositories)
  1. Add the wp-slurp function to your bash functions file.
  2. Open a new terminal windown and run wp-slurp
  3. Profit!
# -*- mode: ruby -*-
# vi: set ft=ruby :
vagrant_dir = File.expand_path(File.dirname(__FILE__))
Vagrant.configure("2") do |config|
# Store the current version of Vagrant for use in conditionals when dealing
# with possible backward compatible issues.
vagrant_version = Vagrant::VERSION.sub(/^v/, '')
@morganestes
morganestes / .readme.md
Last active November 9, 2022 18:07
Create multiple sites with wp-cli in WordPress multisite for testing.

These commands will install multiple dummy sites in a WordPress Multisite environment.

I wrote this to easily create an environment to work on https://core.trac.wordpress.org/ticket/15317.

Usage

Shell

In the terminal, inside your WordPress directory: simply copy, paste, and run the one-line command.

You can also add it to a location available in your $PATH and invoke the script from the shell.

@morganestes
morganestes / .my-hacks.php.md
Last active September 21, 2015 18:20
Plugins & Themes using my-hacks.php

Plugins

  • authimage
  • ktai-entry
  • ktai-style
  • persian-world (translation string)
  • plugins-genius (_deprecated_file() call)
  • pt-variants
  • super-switch
  • wp-lead-plus-free-squeeze-pages-creator
@morganestes
morganestes / .git-commands.md
Last active June 17, 2016 18:48
Custom Git commands for bash

Git commands that I use enough that I decided to write them down.

@morganestes
morganestes / openpgp.txt
Created October 27, 2015 04:22
OpenKeychain API Tests
This Gist confirms the Linked Identity in my OpenPGP key, and links it to this GitHub account.
Token for proof:
[Verifying my OpenPGP key: openpgp4fpr:fec64e0b77737647fa0c5b34bb579336dd3efab9]
@morganestes
morganestes / provision-post.sh
Created January 4, 2016 22:29
VVV post-provision script
#!/bin/bash
#
# Runs commands directly after provision.sh completes, during setup for VVV.
# Installs Memcached for PHP (VVV already loads Memcached, just not the PHP module)
apt-get install php5-memcached -y
# Installs Redis and makes it available to PHP
apt-get install redis-server php5-redis -y
@morganestes
morganestes / .you-git-me-going
Created January 8, 2016 21:46
Custom Git commands for my workflow
This is a collection of Git commands I use on a regular basis.