def fail(reason=nil, options={})
      case reason
      when Errno::EACCES
        STDERR.puts reason.message
        STDERR.puts "Try elevating privilege (sudo/runas) before invoking this command."
        code = 2
      when Exception
        STDOUT.puts "Unexpected #{reason.class.name}: #{reason.message}"
        STDOUT.puts "We apologize for the inconvenience. You may try connecting as root"
        STDOUT.puts "to work around this problem, if you have sufficient privilege."
        unless @log_sink.string.empty?
          STDERR.puts
          STDERR.puts("Debugging information:")
          STDERR.puts(@log_sink.string)
        end
        code = 50
      when String
        STDOUT.puts reason
        code = 50
      when Integer
        code = reason
      else
        code = 50
      end

      puts Usage.scan(__FILE__) if options[:print_usage]
      exit(code)
    end
def fail(reason=nil, options={})
      case reason
      when Errno::EACCES
        STDERR.puts reason.message
        STDERR.puts "Try elevating privilege (sudo/runas) before invoking this command."
        code = 2
      when Exception
        STDOUT.puts "Unexpected #{reason.class.name}: #{reason.message}"
        STDOUT.puts "We apologize for the inconvenience. You may try connecting as root"
        STDOUT.puts "to work around this problem, if you have sufficient privilege."
        unless @log_sink.string.empty?
          STDERR.puts
          STDERR.puts("Debugging information:")
          STDERR.puts(@log_sink.string)
        end
        code = 50
      when String
        STDOUT.puts reason
        code = 50
      when Integer
        code = reason
      else
        code = 50
      end

      puts Usage.scan(__FILE__) if options[:print_usage]
      exit(code)
    end
Print error on console and exit abnormally

 === Parameters
 msg(String):: Error message, default to nil (no message printed)
 print_usage(Boolean):: Whether script usage should be printed, default to false

 === Return
 R.I.P. does not return