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 | |
function help { | |
echo "Usage: wait-for port [timeout]" | |
echo " port is a TCP port number, or the service name (for instance http, ssh)" | |
echo " timeout is expressed in seconds" | |
echo " optional (defaulted to 30)" | |
echo " if <= 0, no timeout" | |
exit 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
git rev-parse --symbolic-full-name --abbrev-ref HEAD |
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 | |
find . -path "*/CVS/Entries*" |
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
Clean whitespace "problems" : | |
Find: [\t ]+$ | |
Replace with: (nothing) | |
with Regex mode |
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 | |
function color { | |
echo -e "\x1b[${2}m$1\x1b[0m" | |
} |
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 | |
from="$1" | |
to="$2" | |
for file in $(git show --numstat $from --pretty=format: | cut -f3) | |
do | |
git diff $from $to -- $file | |
done |
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
sudo apt-get install scons g++-multilib | |
scons sample=shell regexp=interpreted |
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
test "Bookmark toString works", -> | |
### given ### | |
bookmark = new Bookmark "lien@localhost", "lien", new Point 0, 1 | |
### when ### | |
text = bookmark.toString() | |
### then ### | |
equals "Bookmark \"lien\" lien@localhost at (0,1)", text, "Bookmark.toString()" |
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
# Handlers | |
nope = (tx, obj) -> | |
displayResult = (tx, rs) -> | |
alert "Succeeded!" | |
displayError = (tx, err) -> | |
alert "Error: #{err.message}" | |
class Storage |
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 | |
error="91" | |
warning="35" | |
( $1 3>&1 1>&2- 2>&3- ) | sed \ | |
-e "s/^\(.* ERROR - \)\(.*\)$/\1\x1b[${error}m\2\x1b[0m/" \ | |
-e "s/^\(.* WARNING - \)\(.*\)$/\1\x1b[${warning}m\2\x1b[0m/" |