View gist:df5116bf8634f017ca06
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
# Update from SVN repo | |
svn up | |
# Commit the updates into Git repo, using the last revision id of SVN | |
git add .; git commit -m r`svn info $url | grep 'Last Changed Rev' | awk '{ print $4; }'` -n | |
# Merge the feature branch, after CR | |
git merge origin/FEATURE-BRANCH | |
# Run grunt or any pre-svn-commit steps |
View class-microcache-purge.php
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
/** | |
* Micro Cache Purge PHP Class | |
* Sends a request header to nginx to purge the microcache when post are created or updated | |
* Include this file at plugins_loaded or in theme functions.php | |
*/ | |
new Micro_Cache_Purge(); | |
class Micro_Cache_Purge { |
View wp-chosen-tax-metabox.php
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 | |
/** | |
* WordPress Chosen Taxonomy Metabox | |
* Author: Helen Hou-Sandi | |
* | |
* Use Chosen for a replacement taxonomy metabox in WordPress | |
* Useful for taxonomies that aren't changed much on the fly and are | |
* non-hierarchical in nature, as Chosen is for flat selection only. | |
* You can always use the taxonomy admin screen to add/edit taxonomy terms. | |
* Categories need slightly different treatment from the rest in order to |
View get-functions-for-hook.php
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 | |
function debug_get_functions_for_hook( $hook ) { | |
global $wp_filter; | |
if( ! isset( $wp_filter[$hook] ) ) | |
return; | |
$functions = array(); | |
foreach( (array) $wp_filter[$hook] as $key => $actions ) { | |
//$functions = array_merge( $functions, $actions ); |