gitflow | git |
---|---|
git flow init |
git init |
git commit --allow-empty -m "Initial commit" |
|
git checkout -b develop master |
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
composer.lock | |
/vendor |
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
Hello,human. This is just for the gist title. |
[Laravel][] is a PHP framework that's really a joy to work with -- though I did find the initial learning curve a bit steep.
This tutorial describes a minimum set of steps necessary to pull content from a database and dump it to a url using Laravel's Eloquent ORM. For me, that was the breakthrough moment.
Assuming you've got [Laravel installed][install] and the [database configured][configure], here are the steps needed to get your data from the database into a web browser:
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 | |
# | |
# DESCRIPTION: | |
# | |
# Set the bash prompt according to: | |
# * the active virtualenv | |
# * the branch of the current git/mercurial repository | |
# * the return value of the previous command | |
# * the fact you just came from Windows and are used to having newlines in | |
# your prompts. |
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
APP_DEV=static.intermail.dev.$1.jp7.com.br | |
echo "Creating S3 development bucket " $APP_DEV"...\n" | |
aws s3api create-bucket --bucket $APP_DEV --region us-east-1 | |
echo "Setting Static Web Hosting...\n" | |
aws s3api put-bucket-website --bucket $APP_DEV --website-configuration file://website-config.json | |
echo "Bucket" $APP_DEV "created, visit AWS Console to create IAM user for said bucket.\n" | |
APP_QA=static.intermail.qa.$1.jp7.com.br |
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 aws import bucket_exists, upload_path | |
bucket_name = 'cnns-music-vids' | |
directory_to_upload = 'data/' | |
output_s3_directory = 'data/' | |
if bucket_exists(bucket_name): | |
print('the bucket exists!') | |
else: | |
raise ValueError('nah the bucket does not exist') |
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
====== | |
Videos | |
====== | |
DevOps | |
What is DevOps? by Rackspace - Really great introduction to DevOps | |
https://www.youtube.com/watch?v=_I94-tJlovg | |
Sanjeev Sharma series on DevOps (great repetition to really get the DevOps concept) |
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
## | |
## ca-bundle.crt -- Bundle of CA Root Certificates | |
## | |
## Certificate data from Mozilla as of: Sat Dec 29 20:03:40 2012 | |
## | |
## This is a bundle of X.509 certificates of public Certificate Authorities | |
## (CA). These were automatically extracted from Mozilla's root certificates | |
## file (certdata.txt). This file can be found in the mozilla source tree: | |
## http://mxr.mozilla.org/mozilla/source/security/nss/lib/ckfw/builtins/certdata.txt?raw=1 | |
## |
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 | |
public function getImageSizeKeepAspectRatio( $imageUrl, $maxWidth, $maxHeight) | |
{ | |
$imageDimensions = getimagesize($imageUrl); | |
$imageWidth = $imageDimensions[0]; | |
$imageHeight = $imageDimensions[1]; | |
$imageSize['width'] = $imageWidth; |