Skip to content

Instantly share code, notes, and snippets.

View emerham's full-sized avatar

Matthew Brabham emerham

  • Oregon State University
  • Oregon
View GitHub Profile
@emerham
emerham / MigratedPathLookup.php
Created March 15, 2023 16:26 — forked from 5n00p4eg/MigratedPathLookup.php
Drupal 8 migrate menu links with node references
<?php
namespace Drupal\oht_migrate\Plugin\migrate\process;
use Drupal\Core\Plugin\ContainerFactoryPluginInterface;
use Drupal\migrate\Annotation\MigrateProcessPlugin;
use Drupal\migrate\Plugin\migrate\process\MigrationLookup;
use Drupal\migrate\Plugin\MigratePluginManagerInterface;
use Drupal\migrate\Plugin\MigrationInterface;
use Drupal\migrate\ProcessPluginBase;
@emerham
emerham / id-differences-for-dev-and-prod.json
Last active October 10, 2017 19:40 — forked from jaredkosanovic/id-differences-for-dev-and-prod.json
The old IDs are what are currently in prod, and the new IDs are what's currently in dev. If the building name changed in addition to the ID, then it's not included in this file since we don't have a good way to know that the buildings were the same.
{
"buildings": {
"OSU Open Campus - Corvallis": {
"new": "ce450c4443a09e5635165df7b4a8bd74",
"old": "ce450c4443a09e5635165df7b4a8bd74"
},
"North Porch Cafe": {
"new": "dde04c526a9605a44084a4a9f7e08f96",
"old": "46aca402f531a0d513ef8d9413533866"
},
@emerham
emerham / innobackupex-restore.sh
Last active August 29, 2015 14:26 — forked from dalecaru/innobackupex-restore.sh
Scripts to create and restore full and incremental backups (for all databases on server) using innobackupex from Percona.
#!/bin/sh
#
# Script to prepare and restore full and incremental backups created with innobackupex-runner.
#
# This script is provided as-is; no liability can be accepted for use.
#
INNOBACKUPEX=innobackupex-1.5.1
INNOBACKUPEXFULL=/usr/bin/$INNOBACKUPEX
TMPFILE="/tmp/innobackupex-restore.$$.tmp"