Skip to content

Instantly share code, notes, and snippets.

View scottnath's full-sized avatar

Scott Nath scottnath

View GitHub Profile
@scottnath
scottnath / mpo2gif
Created September 21, 2012 14:46 — forked from fuba/mpo2gif
convert a .mpo file to an animation gif
#!/bin/sh
# mpo2gif
# convert a .mpo file to a animation gif.
# this idea is from http://www.imagemagick.org/discourse-server/viewtopic.php?f=1&t=16275
# this script requires exiftool and imagemagick.
rjpg=/tmp/$$_r.jpg
ljpg=/tmp/$$_l.jpg
echo $1
@scottnath
scottnath / 0-env-url-override.php
Created February 22, 2012 15:51 — forked from mjangda/0-env-url-override.php
How to use WordPress across environments without needing to mess with URLs in the database.
<?php
// This is the meat of the plugin and should go in mu-plugins/0-env-url-override.php
// Only load these filters if we're not in the production environment
if ( defined( 'ENV_NOT_PRODUCTION' ) && ENV_NOT_PRODUCTION ) {
// This always needs to be filtered
add_filter( 'site_url', 'env_filter_site_url', 0 );
// We don't filter home_url in the admin so that we get production URLs for posts.
// This does break certain links like "Preview/View Post", however.