This file contains hidden or 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 ruby | |
require 'rubygems' | |
require 'pp' | |
require 'fog' | |
require 'highline/import' | |
def get_password(prompt="Enter password:") | |
ask(prompt) {|q| q.echo = false} | |
end |
This file contains hidden or 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
# Variables goes hither | |
declare -a FILES | |
IFS=" | |
" | |
FILES=$(git diff --cached --name-only --diff-filter=ACM ) | |
# I we don't have puppet-lint, so just exit and leave them be. | |
which puppet-lint >/dev/null 2>&1 || exit | |
# I we don't have puppet, so just exit and leave them be. | |
which puppet >/dev/null 2>&1 || exit |
This file contains hidden or 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 'xmlrpc/client' | |
# A useful helper for running Confluence XML-RPC from Ruby. Takes care of | |
# adding the token to each method call (so you can call server.getSpaces() | |
# instead of server.getSpaces(token)). Also takes care of re-logging in | |
# if your login times out. | |
# | |
# Usage: | |
# | |
# server = Confluence::Server.new :server => 'http://confluence02.lightningsoure.com' |
This file contains hidden or 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
class Github | |
include HTTParty | |
base_uri 'https://api.github.com' | |
end | |
Github.post("/user/repos", :query => { | |
:access_token => @token | |
}, | |
:body => { | |
:name => name, |
This file contains hidden or 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
# | |
# Eric Lindvall <[email protected]> | |
# | |
# Update the process name for the process you're running in. | |
# | |
# This will allow top, lsof, and killall to see the process as the | |
# name you specify. | |
# | |
# Just use: | |
# |
NewerOlder