Use launchy for opening browsers

This commit is contained in:
Calen Pennington
2013-05-03 11:40:20 -04:00
parent 8e54991b89
commit 9743e84d0b

View File

@@ -601,15 +601,7 @@ task :showdocs, [:options] do |t, args|
end
Dir.chdir("#{path}/build/html") do
if RUBY_PLATFORM.include? 'darwin' # mac os
sh('open index.html')
elsif RUBY_PLATFORM.include? 'linux' # make more ubuntu specific?
sh('sensible-browser index.html') # ubuntu
else
raise "\nUndefined how to run browser on your machine.
Please use 'rake builddocs' and then manually open
'mitx/#{path}/build/html/index.html."
end
Launchy.open('index.html')
end
end