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/bash | |
# Example | |
# ./terminus-org-primary-domain.sh <ORG_ID> | |
# Exit on error | |
set -e | |
ORG_ID=$1 | |
TEMP_FILE=$(echo "/tmp/$ORG_ID-primary-domains.csv") |
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 | |
/** | |
* @file | |
* Contains \Project\composer\ComposerPrivateAuth. | |
*/ | |
namespace Project\composer; | |
use Composer\Script\Event; |
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
# Using the pantheon recipe / wordpress_network framework, we add a config to the | |
# appserver_nginx service to use our own server and vhost files. Copy the files lando | |
# uses and on the wordpress_network.conf.tpl and added wp/ to the rewrite | |
# rules so lando knows where our WP files live within our Bedrock setup. | |
appserver_nginx: | |
type: nginx | |
ssl: true | |
config: | |
server: 'private/config/lando/nginx.conf.tpl' |
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 | |
/** | |
* This is a script to retrieve DB credentials for database connections | |
* | |
*/ | |
/** | |
* Check IP address function | |
*/ |
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 | |
$myFile = new SplFileObject("data.txt"); | |
$ips = []; | |
$count=0; | |
while (!$myFile->eof()) { | |
$ip = trim($myFile->fgets()); | |
// Skip if IPv6 |
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: WPML CLI | |
Plugin URI: https://pantheon.io | |
Description: WPML CLI demo commands | |
Author: Kyle Taylor | |
Version: 1.0.0 | |
Author URI: https://github.com/kyletaylored | |
*/ |
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: WDS Hello World | |
Plugin URI: https://webdevstudios.com/ | |
Description: Teaching the basics of WP-CLI | |
Author: Web Dev Studios | |
Version: 1.0.0 | |
Author URI: https://webdevstudios.com/ | |
*/ | |
class WDS_CLI { |
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 | |
// Punch through the Pantheon edge cache. This is not required | |
// when building a full Drupal site, just so we don't worry about testing. | |
setcookie('NO_CACHE', '1'); | |
/** | |
* Proxy function. | |
* | |
* @return void |
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
$ ./git-auditor.sh 443d26c3-6b6b-4cd4-b102-decb061e8261 | |
--- Upstream Information --- | |
Name: slac-poc-upstream | |
Organization: Pantheon Sales Demo | |
Git: https://github.com/Pantheon-SE/slac-poc-upstream.git | |
Cloning the upstream... | |
Cloning into 'slac-poc-upstream'... | |
remote: Enumerating objects: 12092, done. | |
remote: Counting objects: 100% (12092/12092), done. |
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
window.addEventListener('acquiaLiftContentAvailable', function(event) { | |
function unwrap(wrapper) { | |
// place childNodes in document fragment | |
var docFrag = document.createDocumentFragment(); | |
while (wrapper.firstChild) { | |
var child = wrapper.removeChild(wrapper.firstChild); | |
docFrag.appendChild(child); | |
} | |
// replace wrapper with document fragment |