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
#!/usr/bin/perl -w | |
# | |
# Copyright (c) 2002-2005 David Rudie | |
# All rights reserved. | |
# | |
# Redistribution and use in source and binary forms, with or without | |
# modification, are permitted provided that the following conditions | |
# are met: | |
# 1. Redistributions of source code must retain the above copyright | |
# notice, this list of conditions and the following disclaimer. |
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 | |
// Javascript/HTML hex encode | |
function encode($input) | |
{ | |
$temp = ''; | |
$length = strlen($input); | |
for($i = 0; $i < $length; $i++) | |
$temp .= '%' . bin2hex($input[$i]); | |
return $temp; | |
} |
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
-- SET GLOBAL event_scheduler = ON; | |
-- create table growth_history(tbl_name varchar(64), row_count bigint, time_stamp datetime); | |
DELIMITER $$ | |
CREATE | |
EVENT `document_growth_history` | |
ON SCHEDULE EVERY 1 DAY | |
DO BEGIN |
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
┌─[✗]─[jlroberts@Jeffreys-Mac-Pro-3]─[~/Projects/Shred/Laravel] | |
└──╼ composer require guzzle/guzzle | |
Using version ^3.9 for guzzle/guzzle | |
./composer.json has been updated | |
Loading composer repositories with package information | |
Updating dependencies (including require-dev) | |
Your requirements could not be resolved to an installable set of packages. | |
Problem 1 | |
- Conclusion: don't install guzzle/guzzle v3.9.3 |
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
from requests import get | |
from requests.exceptions import RequestException | |
from contextlib import closing | |
from bs4 import BeautifulSoup | |
from urllib.request import urlopen | |
import urllib.request | |
import ssl | |
def simple_get(url): | |
""" |
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
public function receive() | |
{ | |
// https://developer.authorize.net/api/reference/features/webhooks.html#Event_Types_and_Payloads | |
} | |
public function createWebHook() | |
{ | |
$omh_webhook_api_endpoint = 'https://{yourserver.com}/webhooks/receive'; | |
$json = ' |
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
[ /jlr/sites/legophp.com/framework ] | |
[ jlroberts@iMac ] $ git remote set-url --add --push origin ssh://git@bitbucket.org/jeffreylroberts/legophp-com-framework.git | |
[ /jlr/sites/legophp.com/framework ] | |
[ jlroberts@iMac ] $ git remote set-url --add --push origin git@github.com:LegoPHP/LegoPHP.git | |
[ /jlr/sites/legophp.com/framework ] | |
[ jlroberts@iMac ] $ git remote -v | |
github git@github.com:LegoPHP/LegoPHP.git (fetch) | |
github git@github.com:LegoPHP/LegoPHP.git (push) | |
origin ssh://git@bitbucket.org/jeffreylroberts/legophp-com-framework.git (fetch) | |
origin ssh://git@bitbucket.org/jeffreylroberts/legophp-com-framework.git (push) |
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
'Twas the night before Christmas, when all through the racks | |
Not a server was alerting, not even Compaqs. | |
The backups were written to tapes with care | |
In hopes that later the data would be there. | |
The machines were nestled all snug in their sleds | |
Whilst visions of vengeance danced in their heads; | |
And oncall in his three-wolf and I in my rack. | |
Had just settled down for some syn and some ack. |
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
#!/usr/bin/env bash | |
# repository | |
cd /tmp | |
wget http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm | |
rpm -Uvh epel-release-6-8.noarch.rpm | |
# system update | |
yum -y update | |
yum -y groupinstall "Development Tools" | |
yum -y install libxslt-devel libyaml-devel libxml2-devel gdbm-devel libffi-devel zlib-devel openssl-devel libyaml-devel readline-devel curl-devel openssl-devel pcre-devel git memcached-devel valgrind-devel mysql-devel ImageMagick-devel ImageMagick |
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
#get root access | |
$su - | |
$ cd /tmp | |
#Remove old Ruby | |
$ yum remove ruby | |
# Install dependencies | |
$ yum groupinstall "Development Tools" | |
$ yum install zlib zlib-devel |
NewerOlder