@Deprecated // caused issues https://github.com/holgerbrandl/r4intellij/issues/79
    private static ArrayList<String> getInstallationFromPaths(@NotNull final String scriptName, @NotNull final String[] paths) {
        final ArrayList<String> result = new ArrayList<String>();
        for (String path : paths) {
            // does not work in tests
            final VirtualFile rootVDir = LocalFileSystem.getInstance().findFileByPath(path);
            if (rootVDir != null) {
//                final VirtualFile rScript = rootVDir.findFileByRelativePath("bin/" + scriptName);
                final File rScript = findScript(scriptName, path);
                if (rScript != null) {
                    result.add(FileUtil.toSystemDependentName(rScript.getPath()));
                }
            }
        }
        return result;
    }
@Deprecated     private static ArrayList<String> getInstallationFromPaths(@NotNull final String scriptName, @NotNull final String[] paths) {
        final ArrayList<String> result = new ArrayList<String>();
        for (String path : paths) {
           
            final VirtualFile rootVDir = LocalFileSystem.getInstance().findFileByPath(path);
            if (rootVDir != null) {
                final File rScript = findScript(scriptName, path);
                if (rScript != null) {
                    result.add(FileUtil.toSystemDependentName(rScript.getPath()));
                }
            }
        }
        return result;
    }
@deprecated private static arraylist<string> getinstallationfrompaths(@notnull final string scriptname, @notnull final string[] paths) { final arraylist<string> result = new arraylist<string>(); for (string path : paths) { final virtualfile rootvdir = localfilesystem.getinstance().findfilebypath(path); if (rootvdir != null) { final file rscript = findscript(scriptname, path); if (rscript != null) { result.add(fileutil.tosystemdependentname(rscript.getpath())); } } } return result; }