Skip to content

Instantly share code, notes, and snippets.

@lukewhitehouse
lukewhitehouse / .htaccess
Created September 9, 2016 09:04
301 Redirects stuff
# Redirect entire site from old to new domain
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{HTTP_HOST} ^olddomain\.com$ [OR]
RewriteCond %{HTTP_HOST} ^www\.olddomain\.com$
RewriteRule (.*)$ http://www.newdomain.com/$1 [R=301,L]
</IfModule>
@lukewhitehouse
lukewhitehouse / functions.php
Created November 23, 2016 14:31
WordPress post type permalinks
<?php
/**
* Modify Work permalink to add in category
*/
function mixd_work_permalink_setup( $post_link, $id = 0, $leavename = FALSE ) {
// Test params are anywhere within the URL
if ( strpos('%work_type%', $post_link) === 0 ) {
return $post_link;
} else {
@lukewhitehouse
lukewhitehouse / spots-druid-macros.md
Last active July 21, 2021 23:58
Spots Druid Macros - WoW

Spots Druid Macros

Collection of macros for Druids in World of Warcraft.

Mouseover

Spells cast on a friendly player or yourself

Any non-harmful mouseover macros here will attempt to target a friendly target, failing that it will cast the spell on yourself.

@lukewhitehouse
lukewhitehouse / setup-plantuml.md
Last active May 18, 2024 03:48
How to setup and install PlantUML on Mac OSX and VS Code with Homebrew

How to setup and install PlantUML on Mac OSX and VS Code with Homebrew

Documentation around PlantUML and how to setup (especially when you don't typically work in Java) leave a lot to be desired. Here's a quick run down of how to get plantuml setup and running so you can create, edit, preview and export the diagrams (including C4 Model) in VS Code.

First, ensure you have homebrew installed and updated: https://brew.sh/.

Install the temurin JDK, graphviz and plantuml in that order.

brew install --cask temurin