Permalink
Browse files

Run core with same Ruby version as it was started with.

  • Loading branch information...
moll committed Oct 5, 2017
1 parent 0270171 commit 40c07c5da55c62103218811b420cbd477104fc32
Showing with 2 additions and 6 deletions.
  1. +2 −6 bin/guard
View
@@ -41,10 +41,6 @@ class GuardReloader
Gem.win_platform?
end
def default_system_ruby
RbConfig.ruby
end
def exit_with(code)
exit(code)
end
@@ -98,8 +94,8 @@ class GuardReloader
end
def auto_restart
args = [config.guard_core_path] + config.program_arguments
args.unshift(config.default_system_ruby) if config.windows?
args = [Gem.ruby, config.guard_core_path] + config.program_arguments
loop do
exitcode = config.wait_ignoring_interrupts(config.spawn_with(*args))
config.exit_with(exitcode) if exitcode != 2

0 comments on commit 40c07c5

Please sign in to comment.