This file contains hidden or 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 _sustain_disable_fulfillment_plugin() { | |
if ( ! function_exists( 'deactivate_plugins' ) ) { | |
require_once( $_SERVER['DOCUMENT_ROOT'] . '/wp-admin/includes/plugin.php' ); | |
} | |
deactivate_plugins( 'woocommerce-fulfillment/woocommerce-fulfillment.php', true ); | |
} |
This file contains hidden or 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 | |
if ( php_sapi_name() !== "cli" ) | |
{ | |
exit(1); | |
} | |
// Curl response headers | |
class CurlResponse | |
{ | |
var $headers; |
This file contains hidden or 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 | |
class IP_Access { | |
public $is_restricted = false; | |
private $protected_ips = array( | |
"..." | |
); | |
function __construct($request) | |
{ |
This file contains hidden or 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 | |
######################################### | |
# | |
# This script enables apache virtual hosts | |
# by creating symlinks in | |
# | |
# /private/etc/apache2/sites-enabled | |
# | |
# that point to vhost conf files in | |
# |
This file contains hidden or 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 | |
# from within git repo | |
git checkout master && git branch | grep -v "master" | xargs git branch -D |
This file contains hidden or 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 | |
/** | |
* Auto Deployment Script for GitLab. Uses apache + php to perform tasks. | |
* | |
* | |
* @since deploy 0.2 | |
*/ | |
/** | |
* @internal The following variables are assumed to be valid but minimal validation is performed. |
This file contains hidden or 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 | |
if [ $# -eq 0 ]; then | |
printf "===> Needs s fully-qualified git repo\n" | |
exit | |
fi | |
printf "===> Installing dependencies...\n" | |
apt-get install -y wget nano git |
This file contains hidden or 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 | |
# set display | |
export DISPLAY=":0" | |
# set var to retrieve window id | |
WID=$(xdotool search --onlyvisible --class chromium|head -1) | |
# reload window according to cron schedule | |
if [ -n $WID ]; then |
This file contains hidden or 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
# uncomment if you wish to disable the splash screen | |
disable_splash=1 | |
# uncomment if you get no picture on HDMI for a default "safe" mode | |
#hdmi_safe=1 | |
# uncomment this if your display has a black border of unused pixels visible | |
# and your display can output without overscan | |
disable_overscan=1 |