Skip to content

Instantly share code, notes, and snippets.

View claytoncollie's full-sized avatar
馃彔
Working from home

Clayton Collie claytoncollie

馃彔
Working from home
View GitHub Profile
# Optional Local Debug
# wp config set WP_DEBUG true --raw
# wp config set WP_DEBUG_DISPLAY false --raw
# wp config set WP_DEBUG_LOG true --raw
# Setup defaults
wp post create --post_type=page --post_title=Home --post_status=publish --post_author=1
wp option update show_on_front 'page'
wp option update page_on_front $(wp post list --post_type=page --post_status=publish --posts_per_page=1 --pagename=home --field=ID --format=ids)
wp option update blogdescription ''
name: myproject
recipe: wordpress
config:
php: '7.3'
xdebug: false
proxy:
theme:
@felixarntz
felixarntz / wp-plugin-mu-loader.php
Last active October 10, 2022 12:21
WP Plugin MU Loader
<?php
/**
* Plugin initialization file
*
* @package WP_Plugin_MU_Loader
* @since 1.0.0
*
* @wordpress-plugin
* Plugin Name: WP Plugin MU Loader
* Plugin URI: https://gist.github.com/felixarntz/daff4006112b60dfea677ca08fc0b31c
@keesiemeijer
keesiemeijer / setup-phpunit.sh
Last active October 16, 2025 20:56
Setup PHPUnit for use in the Local by Flywheel app
#!/usr/bin/env bash
# ===============================================================================
# Script to install PHPUnit in the Local by Flywheel Mac app
# These packages are installed
#
# PHPUnit, curl wget, rsync, git, subversion and composer.
#
# WordPress is installed in the `/tmp/wordpress` directory for use by PHPUnit.
# The WordPress test suite is installed in the `/tmp/wordpress-tests-lib` directory.
@amboutwe
amboutwe / yoast_seo_primary_category_disable.php
Last active May 3, 2021 19:35
Disable Yoast SEO Primary Category Feature
<?php
/********* DO NOT COPY THE PARTS ABOVE THIS LINE *********/
/* Disable Yoast SEO Primary Category Feature
* Credit: Yoast development team
* Last Tested: Jan 24 2017 using Yoast SEO 4.1 on WordPress 4.7.1
*/
add_filter( 'wpseo_primary_term_taxonomies', '__return_empty_array' );
# Ignore everything #
**
!wp-content/
wp-content/**
!wp-content/themes/
!wp-content/plugins/
wp-content/themes/**
wp-content/plugins/**
# Add two rules for each Theme or Plugin you want to include:
@PurpleBooth
PurpleBooth / README-Template.md
Last active December 16, 2025 09:47
A template to make good README.md

Project Title

One Paragraph of project description goes here

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Prerequisites

@Rarst
Rarst / r-debug.php
Last active June 12, 2025 01:56
R Debug (set of dump helpers for debug)
<?php
/*
Plugin Name: R Debug
Description: Set of dump helpers for debug.
Author: Andrey "Rarst" Savchenko
Author URI: https://www.rarst.net/
License: MIT
*/