return export(url, uniqueDirectory);
}
public static File export(String url, File directory) {
url = decode(url);
IRepositoryResource resource = SVNUtility.asRepositoryResource(url,
false);
if (resource == null) {
// TODO externalize
logger.severe("'" + url + "' " + "is not a svn resource"); //$NON-NLS-1$//$NON-NLS-2$ //$NON-NLS-3$
return null;
}
IRepositoryResource[] resources = { resource };
int depth = 0;
ExportOperation exportOperation = new ExportOperation(resources,
directory.getAbsolutePath(), depth);
exportOperation.run(new NullProgressMonitor());
String name = resource.getName();
return FileUtil.getFile(name, directory);
}