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
require 'oauth' | |
consumer = OAuth::Consumer.new( | |
"CONSUMER_KEY", | |
"CONSUMER_SECRET", | |
{ | |
site: "https://trello.com", | |
request_token_url: "https://trello.com/1/OAuthGetRequestToken", | |
authorize_url: "https://trello.com/1/OAuthAuthorizeToken", | |
access_token_url: "https://trello.com/1/OAuthGetAccessToken" |
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
git br | grep -v master | xargs git br -D |
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
dd if=/dev/zero of=tempfile bs=1M count="SOME SIZE" |
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
require 'aws-sdk' | |
AWS.config(:access_key_id => ACCESS_KEY, :secret_access_key => SECRET_KEY, :ec2_endpoint => REGION, :elb_endpoint => ELB_REGION) | |
@elb_client = AWS::ELB.new().client | |
# show description | |
@elb_client.describe_load_balancers({load_balancer_names: ["ELB_NAME"]}) | |
# get a lb |
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
var randobet = function(n) { | |
var a = 'abcdefghijklmnopqrstuvwxyz' | |
+ 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' | |
+ '0123456789'; | |
a = a.split(''); | |
var s = ''; | |
for (var i = 0; i < n; i++) { | |
s += a[Math.floor(Math.random() * a.length)]; | |
} | |
return s; |
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
if [ ! -d "DIR_NAME" ]; then mkdir "DIR_NAME";fi |
NewerOlder