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
$ cat script.sh | bash -c 'cat - >/tmp/$$.sh; bash /tmp/$$.sh $@; rm -f /tmp/$$.sh' -- -v foobar | |
args are -v foobar |
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
DEBUG:libcloud.compute.ssh:Connecting to server | |
DEBUG:libcloud.compute.ssh:Closing server connection | |
DEBUG:libcloud.compute.ssh:Connecting to server | |
DEBUG:libcloud.compute.ssh:Closing server connection | |
DEBUG:libcloud.compute.ssh:Connecting to server | |
DEBUG:libcloud.compute.ssh:Closing server connection | |
DEBUG:libcloud.compute.ssh:Connecting to server | |
DEBUG:libcloud.compute.ssh:Closing server connection | |
DEBUG:libcloud.compute.ssh:Connecting to server | |
DEBUG:libcloud.compute.ssh:Closing server connection |
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
$ lsb_release -a | |
No LSB modules are available. | |
Distributor ID: Ubuntu | |
Description: Ubuntu 12.04 LTS | |
Release: 12.04 | |
Codename: precise | |
$ curl --version | |
curl 7.22.0 (x86_64-pc-linux-gnu) libcurl/7.22.0 OpenSSL/1.0.1 zlib/1.2.3.4 libidn/1.23 librtmp/2.3 | |
Protocols: dict file ftp ftps gopher http https imap imaps ldap pop3 pop3s rtmp rtsp smtp smtps telnet tftp |
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
#!/bin/bash | |
files="" | |
for arg in $@; do | |
files="$files $(find test/ -name ${arg}_test.rb)" | |
done | |
echo "Testing: $files" | |
/Users/cicero/.rvm/rubies/ruby-1.8.6-p420/bin/ruby -I"lib:test" "/Users/cicero/.rvm/gems/ruby-1.8.6-p420@global/gems/rake-0.8.7/lib/rake/rake_test_loader.rb" $files |
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
#!/bin/bash | |
clear | |
echo -ne " \n\n\n\n" | |
echo -ne " a fantastic shrimp voyage\r" | |
sleep 2 | |
echo -ne " * ( \r" | |
sleep 1 | |
echo -ne " 9 ( \r" | |
sleep 1 |
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 Employee < Person | |
include SalaryUtils | |
attr_accessor :annual_salary | |
def weekly_salary | |
hourly_rate(annual_salary) * 40 | |
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
for (anItem in hudson.model.Hudson.instance.getQueue().getItems()) { | |
anItem.doCancelQueue() | |
} |
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 Book | |
attr_reader :title | |
DONT_CAPITALIZE = %w(and or the an of in a) | |
def title=(title) | |
@title = title.capitalize.split.map do |word| | |
if DONT_CAPITALIZE.include?(word.downcase) | |
word | |
else |
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
def translate(phrase) | |
phrase.split.inject([]) do |final_pigs, word| | |
char = word.split(//) | |
if char[0].match(/[aeiou]/) | |
final_pigs << "#{word}ay" | |
else | |
new_string = char | |
until new_string[0].match(/[aeio]/) | |
new_string << new_string.shift | |
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
alias vimf="~/vimf.sh" |