Skip to content
Browse files

Point to ruby 1.8 shim

Using a shim allows us to catch when 1.8 of ruby is not present and provide other options.

#ignore
  • Loading branch information...
1 parent 7251582 commit bbcc027983356e1127d07760f9d98bf9905615af @infininight infininight committed Jun 18, 2014
View
2 Commands/Diff Labels….plist
@@ -25,7 +25,7 @@ difflabels=( $difflabels )
#echo "0:" ${difflabels[0]}
#echo "1:" ${difflabels[1]}
-/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby -I "$TM_BUNDLE_SUPPORT/lib/"<<END
+ruby18 -I "$TM_BUNDLE_SUPPORT/lib/"<<END
require 'p4_diff'
Perforce::diff_files_in_revisions("@${difflabels[0]}", "@${difflabels[1]}", "Perforce—Diff Labels…")
END
View
2 Commands/Diff With Base.plist
@@ -5,7 +5,7 @@
<key>beforeRunningCommand</key>
<string>nop</string>
<key>command</key>
- <string>#!/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby -w
+ <string>#!/usr/bin/env ruby18 -w
$LOAD_PATH &lt;&lt; ENV['TM_BUNDLE_SUPPORT'] + "/lib"
require 'p4_diff'
View
2 Commands/Diff With Revision In Label….plist
@@ -32,7 +32,7 @@ fi
revs=( $revs )
-/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby -I "$TM_BUNDLE_SUPPORT/lib/"&lt;&lt;END
+ruby18 -I "$TM_BUNDLE_SUPPORT/lib/"&lt;&lt;END
require 'p4_diff'
Perforce::diff_active_file("@$revs", "Perforce—Diff With Revision in Label…")
END
View
2 Support/lib/p4_diff.rb
@@ -1,4 +1,4 @@
-#!/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby -w
+#!/usr/bin/env ruby18 -w
require 'pathname'
require ENV['TM_SUPPORT_PATH'] + "/lib/progress"

0 comments on commit bbcc027

Please sign in to comment.
Something went wrong with that request. Please try again.