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/sh | |
for js in $(git diff-index --name-only HEAD); do | |
echo Checking $js | |
if ( [ -f $js ] ); then | |
if jsl --process $js > /dev/null ; then | |
echo $js | |
else | |
echo "js files failed $js" | |
jsl -nologo -nofilelisting -nosummary --process $js |
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 "time" | |
party_time = Time.parse("5/04/2012 6:00:00 P.M.") | |
trap(:INT){puts ""} | |
loop do | |
seconds_left = party_time.to_i - Time.now.to_i | |
print "\rSeconds left to party: #{seconds_left}" | |
sleep(1) | |
end |
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/sh | |
# | |
# Usage | |
# copy_dotfiles user@machine | |
# | |
FILES=".vim .vimrc .inputrc .gitconfig" | |
cd $HOME | |
tar cL $FILES | ssh -C $1 'tar vx' |
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
[ | |
{ | |
"id": 1, | |
"name": { | |
"first": "Guillermo", | |
"last": "Alvarez" | |
}, | |
"child": [ | |
{ | |
"name": "pepe", |
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
$ bundle install | |
Fetching source index for http://rubygems.org/ | |
Using rake (0.9.2.2) | |
Installing rake-hooks (1.2.3) | |
Using bundler (1.0.21) | |
Your bundle is complete! Use `bundle show [gemname]` to see where a bundled gem is installed. | |
😳 15:35:21 guillermo@Guillermos-MacBook-Pro:/tmp/asdf ruby-1.9.2-p290 | |
$ cat Gemf | |
Gemfile Gemfile.lock | |
😳 15:35:21 guillermo@Guillermos-MacBook-Pro:/tmp/asdf ruby-1.9.2-p290 |
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
$ cat test/test_id_method.rb | |
require 'test/unit' | |
require 'ostruct' | |
print "\n", RUBY_VERSION, "\n" | |
class TestIdMethod < Test::Unit::TestCase | |
def test_id_method |
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 | |
quit() | |
{ | |
jobs -p | xargs kill | |
} | |
trap quit SIGINT | |
cvlc http://streaming.fosdem.org/fosdem/janson.webm.m3u & | |
cvlc http://streaming.fosdem.org/fosdem/k-auditorium.webm.m3u & |
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 | |
case $1 in | |
*_EDITMSG|*MERGE_MSG|*_TAGMSG ) | |
/usr/local/bin/vim $1 | |
;; | |
*.md|*.txt ) | |
/usr/local/bin/mmdc $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
package rsa_test | |
import ( | |
"crypto/rand" | |
"crypto/rsa" | |
"crypto/sha1" | |
"crypto/x509" | |
"encoding/pem" | |
"io" | |
"testing" |
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 | |
# This is a unix wrapper around the erlang vm. It provides the following functionality: | |
# | |
# * Spawns in foreground | |
# * Handle SIGHUP and call RELOADFUNC | |
# * Handle SIGTERM SIGQUIT and SIGINT telling to the vm to quit | |
# * Dies if the vm dies (for example kernel killing because out of memory) | |
# | |
# Forks and improvements are welcome. |