This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# Provides a way to compare a fork against the original it is based | |
# on so you can get a general idea of what is in a fork. | |
# | |
# git-fork-compare <original> <fork> | |
TMP_GIT=`mktemp -d`; | |
rmdir $TMP_GIT; | |
git clone -q $2 $TMP_GIT; | |
cd $TMP_GIT; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sys | |
import re | |
from code import InteractiveInterpreter | |
import znc | |
class pyeval(znc.Module, InteractiveInterpreter): | |
module_types = [znc.CModInfo.UserModule, znc.CModInfo.NetworkModule] | |
description = 'Evaluates python code' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
# See bigdawggi's comment below for a good combined example | |
// Pre-3.3 | |
function cf_google_search_kill_wp_search( $where, $query ) { | |
global $wp_the_query; | |
if( ! is_admin() && $query->is_search() && $query === $wp_the_query ) { | |
$where = ' AND 1=0'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<link rel="stylesheet" href="http://twitter.github.com/bootstrap/assets/css/bootstrap.css" type="text/css"> | |
<style type="text/css"> | |
code { display: block; } | |
pre { color: green; } | |
</style> | |
</head> | |
<body> | |
<h1>Balanced Sample - Collect Bank Account Information</h1> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env php | |
<?php | |
/** | |
* CSSTidy - Command Line Interface (CLI) | |
* | |
* Command Line Interface that try to mimic as much as possible the C++ CLI | |
* version of csstidy. It should be a drop in replacment for the C++ CLI that is | |
* no longuer maintain. New settings like css_level are added. | |
* | |
* Copyright 2005, 2006, 2007 Florian Schmitz |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
Oh_Shuddup::on_load( array( 'get_theme_data' ) ); | |
/** | |
* Shuts up deprecated messages for specific functions. | |
*/ | |
class Oh_Shuddup { | |
static $functions; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* | |
Plugin Name: Junction fixes for plugins | |
Plugin URI: http://interconnectit.com/ | |
Description: Junctioning files into the WordPess plug-ins folder causes problems with php 5.3 for plugin_url, this tries to fix it. Place in the wp-content/mu-plugins folder so it loads before all other plugins. | |
Author: James R Whitehead | |
Version: 0.0.0.0.0.0.2 | |
Author URI: http://interconnectit.com | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Example for writing a WP plugin that adds a custom post type and flushes | |
* rewrite rules only once on initialization. | |
*/ | |
/** | |
* On activation, we'll set an option called 'my_plugin_name_flush' to true, | |
* so our plugin knows, on initialization, to flush the rewrite rules. | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Create a flexible, responsive prompt. | |
# Based on the Responsive Prompt | |
# http://jondavidjohn.com/blog/2012/12/how-to-accomplish-a-responsive-bash-prompt | |
working_directory() { | |
dir=`pwd` | |
in_home=0 | |
if [[ `pwd` =~ ^$HOME($|\/) ]]; then | |
dir="~${dir#$HOME}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php # -*- coding: utf-8 -*- | |
/** | |
* Plugin Name: MLP Addon: Sync post meta fields | |
* Plugin URI: https://gist.github.com/toscho/6393c79aacba0983a96a | |
* Description: Create a custom field, put it into the MLP translation box, and sync it across the sites. | |
* Version: 2015.03.03 | |
* Required: 4.0 | |
* Author: Thomas Scholz <info@toscho.de> | |
* Author URI: http://toscho.de | |
* License: MIT |
OlderNewer