diff --git a/Rakefile b/Rakefile index ed35586..7cbdc11 100644 --- a/Rakefile +++ b/Rakefile @@ -1,6 +1,6 @@ require 'rake' require 'rake/testtask' -require 'rake/rdoctask' +require 'rdoc/task' begin require 'jeweler' diff --git a/lib/qwandry/launcher.rb b/lib/qwandry/launcher.rb index 1956ecc..743e940 100644 --- a/lib/qwandry/launcher.rb +++ b/lib/qwandry/launcher.rb @@ -25,10 +25,10 @@ module Qwandry # Launches a Package or path represented by a String. Unless `editor` will # check against the environment by default. def launch(package, editor=nil) - editor ||= @editor || ENV['VISUAL'] || ENV['EDITOR'] + editor ||= @editor || ENV['QWANDRY_EDITOR'] || ENV['VISUAL'] || ENV['EDITOR'] if (!editor) || (editor =~ /^\s*$/) # if the editor is not set, or is blank, exit with a message: - puts "Please either set EDITOR or pass in an editor to use" + puts "Please set QWANDRY_EDITOR, VISUAL or EDITOR, or pass in an editor to use" exit 1 end