private String rri(boolean windows, String searchTerm) throws IOException, InterruptedException { File commandFile = windows ? RubyPlugin.getStoragePath("rri.bat") : RubyPlugin.getStoragePath("rri.sh"); File resultFile = RubyPlugin.getStoragePath("ri_result.txt");  if (!commandFile.exists()) { createCommandFile(windows, resultFile, commandFile); }  String result = null;  if (windows) { getOutput('"' + commandFile.getPath() + '"' + ' ' + '"' + searchTerm + '"', false); } else { try { getOutput(commandFile.getPath() + ' ' + searchTerm, false); } catch (IOException e) { if (e.getMessage().indexOf("rri.sh: cannot execute") != -1) { result = jEdit.getProperty("ruby.search-documentation.permission", new String[] {commandFile.getPath()}); } else { throw e; } } }  if(result == null) { result = RubyPlugin.readFile(resultFile); }  return result;
private String rri(String searchTerm) throws IOException, InterruptedException { File resultFile = CommandUtils.getStoragePath("ri_result.txt"); String command = getRriCommand(resultFile, searchTerm); CommandUtils.getOutput(command, false); return RubyPlugin.readFile(resultFile);
    private String rri(boolean windows, String searchTerm) throws IOException, InterruptedException {        File commandFile = windows ? RubyPlugin.getStoragePath("rri.bat") : RubyPlugin.getStoragePath("rri.sh");        File resultFile = RubyPlugin.getStoragePath("ri_result.txt");        if (!commandFile.exists()) {            createCommandFile(windows, resultFile, commandFile);        }        String result = null;        if (windows) {            getOutput('"' + commandFile.getPath() + '"' + ' ' + '"' + searchTerm + '"', false);        } else {            try {                getOutput(commandFile.getPath() + ' ' + searchTerm, false);            } catch (IOException e) {                if (e.getMessage().indexOf("rri.sh: cannot execute") != -1) {                    result = jEdit.getProperty("ruby.search-documentation.permission", new String[] {commandFile.getPath()});                } else {                    throw e;                }            }        }        if(result == null) {            result = RubyPlugin.readFile(resultFile);        }        return result;    }