Kind of continue from the other gist how to install LAMP on an Amazon AMI
##Install git
sudo yum install git-core
##Create ssh directory since it doesn't exists by default on the Amazon AMI
| ### Keybase proof | |
| I hereby claim: | |
| * I am fake-or-dead on github. | |
| * I am fake_or_dead (https://keybase.io/fake_or_dead) on keybase. | |
| * I have a public key ASB364T21PGDbWi6B3_ar-UcVBRf8pqxDHKOHke3fAmzhwo | |
| To claim this, I am signing this object: |
| # download gallery thanks playboy cdn :D | |
| curl http://playboy.co.th/cdn/image/\[0000-9999\] -O | |
| # filter out playboy logo | |
| find . -size 26155c -delete | |
| find . -size 37091c -delete | |
| # rename file to .jpg | |
| find . -name '????' -exec bash -c 'mv $0 $0.jpeg' {} \; |
| dynos, apis = {}, {} | |
| dyno, method, api, connect, service = '','','','','' | |
| File.open('sample.log', "r") do |file| | |
| file.each_line do |line| | |
| # regular from this http://rubular.com/r/uwuiKelesS | |
| target_api = /(method=GET path=\/api\/users\/\d+\/(count_pending_messages|get_messages|get_friends_progress|get_friends_score))|(method=(GET|POST) path=\/api\/users\/\d+ )/ | |
| next unless line.match(target_api) | |
| line.split(': ')[1].split(' ').each do |methods| | |
| k,v = methods.split('=') |
| require "formula" | |
| class Tesseract < Formula | |
| desc "OCR (Optical Character Recognition) engine" | |
| homepage "https://github.com/tesseract-ocr/" | |
| url "https://tesseract-ocr.googlecode.com/files/tesseract-ocr-3.02.02.tar.gz" | |
| sha1 "a950acf7b75cf851de2de787e9abb62c58ca1827" | |
| revision 3 | |
| bottle do |
Kind of continue from the other gist how to install LAMP on an Amazon AMI
##Install git
sudo yum install git-core
##Create ssh directory since it doesn't exists by default on the Amazon AMI
| (function($) { | |
| console.log("facebook loading..."); | |
| var j; | |
| // check facebook available | |
| if($('#fb-root').length === 0) { | |
| // not found fb-root prepend element to body | |
| $('body').prepend("<div id='fb-root'></div>"); | |
| // and load javascript for facebook | |
| j = document.createElement('script'); | |
| j.type = 'text/javascript'; |
| // re-arrange result to be array("value1", "value2") | |
| $options = array(""); | |
| foreach ($query->result_array() as $key => $value) { | |
| array_push($options, $value['field_name']); | |
| } |
| [PHP] | |
| ;;;;;;;;;;;;;;;;;;; | |
| ; About php.ini ; | |
| ;;;;;;;;;;;;;;;;;;; | |
| ; PHP's initialization file, generally called php.ini, is responsible for | |
| ; configuring many of the aspects of PHP's behavior. | |
| ; PHP attempts to find and load this configuration from a number of locations. | |
| ; The following is a summary of its search order: |
| if (!window.FB) window.FB = { | |
| _apiKey: null, | |
| _session: null, | |
| _userStatus: "unknown", | |
| _logging: true, | |
| _inCanvas: window.location.search.indexOf("fb_sig_in_iframe=1") > -1 || window.location.search.indexOf("session=") > -1 || window.location.search.indexOf("signed_request=") > -1 || window.name.indexOf("iframe_canvas") > -1 || window.name.indexOf("app_runner") > -1, | |
| _https: window.name.indexOf("_fb_https") > -1, | |
| _domain: { | |
| api: "https://api.facebook.com/", | |
| api_read: "https://api-read.facebook.com/", |
| if (!window.FB) window.FB = { | |
| _apiKey: null, | |
| _session: null, | |
| _userStatus: "unknown", | |
| _logging: true, | |
| _inCanvas: window.location.search.indexOf("fb_sig_in_iframe=1") > -1 || window.location.search.indexOf("session=") > -1 || window.location.search.indexOf("signed_request=") > -1 || window.name.indexOf("iframe_canvas") > -1 || window.name.indexOf("app_runner") > -1, | |
| _https: window.name.indexOf("_fb_https") > -1, | |
| _domain: { | |
| api: "https://api.facebook.com/", | |
| api_read: "https://api-read.facebook.com/", |