Skip to content

Instantly share code, notes, and snippets.

View cdcarson's full-sized avatar

Chris Carson cdcarson

View GitHub Profile
mkdir myapp && cd myapp
git init
<?php
//in index.php…
echo 'hello world';
eb init
- myapp
- .elaticbeanstalk
- config
- .gitignore
- index.php
#.gitignore
.DS_Store
.idea
vendor
.elasticbeanstalk/
## BEGIN WORDPRESS ##
# ignore everthing...
/wp-content/*
git add -A
git commit -m 'initial commit'
SetEnv IS_DEV_LOCAL 1
SetEnv DEV_DB_HOST localhost
SetEnv DEV_DB_USER webapp
SetEnv DEV_DB_PASS SuperSecret123
# get the latest WordPress
curl http://wordpress.org/latest.tar.gz -o latest.tar.gz
# extract the archive
tar -zxvf latest.tar.gz
# move it to the root...
mv wordpress/* ./
# delete the latest.tar.gz archive and
<?php
/**
* Add the composer autoload
*/
require_once __DIR__ . '/vendor/autoload.php';
/**
* Conditional environment statement
*/
@cdcarson
cdcarson / get_option_event_end.php
Last active August 29, 2015 14:03
Event Publisher API examples
use NowZoo\EventPublisher\API;
$start = API::get_option_event_end();
// object(Carbon\Carbon)#4 (3) {
// ["date"]=>
// string(19) "2014-07-04 20:00:00"
// ["timezone_type"]=>
// int(3)
// ["timezone"]=>
// string(15) "America/Chicago"