Skip to content

Instantly share code, notes, and snippets.

@pgibler
Created July 26, 2011 16:08
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save pgibler/1107124 to your computer and use it in GitHub Desktop.
Save pgibler/1107124 to your computer and use it in GitHub Desktop.
Patches controller.rb in Riddle to make it compta
Index: ../../../../../Ruby187/lib/ruby/gems/1.8/gems/riddle-1.3.3/lib/riddle/controller.rb
===================================================================
--- ../../../../../Ruby187/lib/ruby/gems/1.8/gems/riddle-1.3.3/lib/riddle/controller.rb (revision )
+++ ../../../../../Ruby187/lib/ruby/gems/1.8/gems/riddle-1.3.3/lib/riddle/controller.rb (revision )
@@ -31,8 +31,8 @@
check_for_configuration_file
cmd = "#{searchd} --pidfile --config \"#{@path}\""
-
+
- if RUBY_PLATFORM =~ /mswin/
+ if RUBY_PLATFORM =~ /mswin|mingw/
system("start /B #{cmd} 1> NUL 2>&1")
else
`#{cmd}`
@@ -53,7 +53,7 @@
stop_flag = 'stop' if Riddle.loaded_version.split('.').first == '0'
cmd = %(#{searchd} --pidfile --config "#{@path}" --#{stop_flag})
- if RUBY_PLATFORM =~ /mswin/
+ if RUBY_PLATFORM =~ /mswin|mingw/
system("start /B #{cmd} 1> NUL 2>&1")
else
`#{cmd}`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment