Skip to content

Instantly share code, notes, and snippets.

View jberkel's full-sized avatar

Jan Berkel jberkel

View GitHub Profile
%p#copyright
Copyright © 2007-2010 SoundCloud Ltd. All rights reserved.
~ link_to("Community Guidelines", community_guidelines_path)
|
%a{:href => terms_and_conditions_path}Terms of Use
|
%a{:href => imprint_path} Imprint
#!/usr/bin/env ruby
#
#
(ARGV.empty? ? Dir['**/*.haml'] : ARGV).each do |f|
lines = IO.readlines(f)
new_lines = []
lines.each_with_index do |l, i|
if l.match(/^\s*=\s*/) && lines[i-1] !~ /^\s*[\/%.=#-]/ && lines[i-1] && lines[i-1].strip.size > 0 && l !~ /\s*=\s*render/
diff --git a/scripts/manage b/scripts/manage
index 604ded0..56c7505 100755
--- a/scripts/manage
+++ b/scripts/manage
@@ -69,7 +69,7 @@ __rvm_install_source() {
if [[ ! -z "$rvm_ruby_patch" ]] ; then
for patch in $(echo $rvm_ruby_patch | tr ',' ' ') ; do
- patch -p1 $patch
+ patch -p1 < $patch || exit $?
Index: gc.c
===================================================================
--- gc.c (revision 12920)
+++ gc.c (working copy)
@@ -22,8 +22,16 @@
#include <setjmp.h>
#include <sys/types.h>
+#ifdef _WIN32
+#include <string.h>
install 1.8.6 --patch /tmp/ruby186gc.patch --trace
rvm 0.1.12 by Wayne E. Seguin ([email protected]) [http://rvm.beginrescueend.com/]
+ [[ -z install ]]
+ [[ ! -z '' ]]
+ [[ ! -z '' ]]
+ [[ 0 -gt 0 ]]
+ [[ 0 -gt 0 ]]
+ [[ ! -z '' ]]
+ [[ -z install ]]
+ [[ ! -z '' ]]
+ [[ ! -z '' ]]
+ [[ 0 -gt 0 ]]
+ [[ 0 -gt 0 ]]
+ [[ ! -z '' ]]
+ result=0
+ case "$rvm_action" in
+ [[ ! -z 1.8.6 ]]
+ /Users/jan/.rvm/scripts/manage install 1.8.6
I/dalvikvm( 937): Failed resolving Lorg/jruby/util/SunSignalFacade$JRubySignalHandler; interface 6015 'Lsun/misc/SignalHandler;'
W/dalvikvm( 937): Link of class 'Lorg/jruby/util/SunSignalFacade$JRubySignalHandler;' failed
E/dalvikvm( 937): Could not find class 'sun.misc.Signal', referenced from method org.jruby.util.SunSignalFacade.trap
W/dalvikvm( 937): VFY: unable to resolve new-instance 6014 (Lsun/misc/Signal;) in Lorg/jruby/util/SunSignalFacade;
W/dalvikvm( 937): VFY: rejecting opcode 0x22 at 0x0000
W/dalvikvm( 937): VFY: rejected Lorg/jruby/util/SunSignalFacade;.trap (Lorg/jruby/Ruby;Lorg/jruby/util/SunSignalFacade$JRubySignalHandler;)Lorg/jruby/runtime/builtin/IRubyObject;
W/dalvikvm( 937): Verifier rejected class Lorg/jruby/util/SunSignalFacade;
D/dalvikvm( 937): GC freed 4773 objects / 399016 bytes in 179ms
W/System.err( 937): java.lang.ArrayIndexOutOfBoundsException
W/System.err( 937): at java.util.HugeEnumSet$HugeEnumSetIterator.next(HugeEnumSet.java:102)
W/dalvikvm( 1041): threadid=3: thread exiting with uncaught exception (group=0x4001aa28)
E/AndroidRuntime( 1041): Uncaught handler: thread main exiting due to uncaught exception
E/AndroidRuntime( 1041): java.lang.RuntimeException: Unable to start activity ComponentInfo{org.jruby/org.jruby.IRB}: org.jruby.exceptions.RaiseException: no such file to load -- builtin/core_ext/symbol
E/AndroidRuntime( 1041): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2401)
E/AndroidRuntime( 1041): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2417)
E/AndroidRuntime( 1041): at android.app.ActivityThread.access$2100(ActivityThread.java:116)
E/AndroidRuntime( 1041): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1794)
E/AndroidRuntime( 1041): at android.os.Handler.dispatchMessage(Handler.java:99)
E/AndroidRuntime( 1041): at android.os.Looper.loop(Looper.java:123)
E/AndroidRuntime( 1041): at android.app.ActivityThread.main(ActivityThread.java:4203)
@jberkel
jberkel / gist:147698
Created July 15, 2009 13:21
twitter_friends_timeline.json
[{"in_reply_to_user_id":null,"text":"s\/B\u00fcrgerthemen\/B\u00fcrgerrechte\/ gna","user":{"following":true,"profile_sidebar_border_color":"87bc44","description":"Diskordischer Evangelist. Moderator der Podcasts Chaosradio Express, dieGesellschafter, Not Safe For Work und mobileMacs.","utc_offset":3600,"profile_text_color":"000000","profile_image_url":"http:\/\/s3.amazonaws.com\/twitter_production\/profile_images\/124176546\/Tim_Pritlove_2009_Logo_256x256_normal.jpg","profile_background_image_url":"http:\/\/s3.amazonaws.com\/twitter_production\/profile_background_images\/7640402\/live-arcade-matrix-quai-huge.jpg","created_at":"Mon Dec 17 22:25:51 +0000 2007","url":"http:\/\/tim.geekheim.de\/","name":"Tim Pritlove","profile_link_color":"0000ff","followers_count":6419,"protected":false,"screen_name":"timpritlove","profile_background_tile":false,"statuses_count":4247,"friends_count":356,"profile_background_color":"9ae4e8","notifications":false,"verified":false,"favourites_count":487,"profile_sidebar_fill_color"
[{"in_reply_to_user_id": null, "text": "s/Bürgerthemen/Bürgerrechte/ gna", "user": {"following": true, "profile_sidebar_border_color": "87bc44", "description": "Diskordischer Evangelist. Moderator der Podcasts Chaosradio Express, dieGesellschafter, Not Safe For Work und mobileMacs.", "utc_offset": 3600, "profile_text_color": "000000", "profile_image_url": "http://s3.amazonaws.com/twitter_production/profile_images/124176546/Tim_Pritlove_2009_Logo_256x256_normal.jpg", "profile_background_image_url": "http://s3.amazonaws.com/twitter_production/profile_background_images/7640402/live-arcade-matrix-quai-huge.jpg", "created_at": "Mon Dec 17 22:25:51 +0000 2007", "url": "http://tim.geekheim.de/", "name": "Tim Pritlove", "profile_link_color": "0000ff", "followers_count": 6419, "protected": false, "screen_name": "timpritlove", "profile_background_tile": false, "statuses_count": 4247, "friends_count": 356, "profile_background_color": "9ae4e8", "notifications": false, "verified": false, "favourites_count": 487, "profile_