Source:
boolean performClone(boolean background) { final URIish uri = cloneSource.getSelection().getURI(); final boolean allSelected = validSource.isAllSelected(); final Collection<Ref> selectedBranches = validSource .getSelectedBranches(); final File workdir = cloneDestination.getDestinationFile(); final String branch = cloneDestination.getInitialBranch(); final String remoteName = cloneDestination.getRemote(); workdir.mkdirs(); if (!workdir.isDirectory()) { final String errorMessage = NLS.bind( UIText.GitCloneWizard_errorCannotCreate, workdir.getPath()); ErrorDialog.openError(getShell(), getWindowTitle(), UIText.GitCloneWizard_failed, new Status(IStatus.ERROR, Activator.getPluginId(), 0, errorMessage, null)); return false; } final CloneOperation op = new CloneOperation(uri, allSelected, selectedBranches, workdir, branch, remoteName); importProject.setGitDir(op.getGitDir()); if (background) { final Job job = new Job(NLS.bind(UIText.GitCloneWizard_jobName, uri .toString())) { @Override protected IStatus run(final IProgressMonitor monitor) { try { op.run(monitor); return Status.OK_STATUS; } catch (InterruptedException e) { return Status.CANCEL_STATUS; } catch (InvocationTargetException e) { Throwable thr = e.getCause(); return new Status(IStatus.ERROR, Activator .getPluginId(), 0, thr.getMessage(), thr); } } }; job.setUser(true); job.schedule(); return true; } else { try { getContainer().run(true, true, op); return true; } catch (InterruptedException e) { MessageDialog.openInformation(getShell(), UIText.GitCloneWizard_CloneFailedHeading, UIText.GitCloneWizard_CloneCanceledMessage); return false; } catch (Exception e) { Activator.logError("Failed to clone", e); MessageDialog.openError(getShell(), UIText.GitCloneWizard_CloneFailedHeading, e.toString()); return false; } } }

Target:
boolean performClone(boolean background) { final URIish uri = cloneSource.getSelection().getURI(); final boolean allSelected = validSource.isAllSelected(); final Collection<Ref> selectedBranches = validSource .getSelectedBranches(); final File workdir = cloneDestination.getDestinationFile(); final String branch = cloneDestination.getInitialBranch(); final String remoteName = cloneDestination.getRemote(); workdir.mkdirs(); if (!workdir.isDirectory()) { final String errorMessage = NLS.bind( UIText.GitCloneWizard_errorCannotCreate, workdir.getPath()); ErrorDialog.openError(getShell(), getWindowTitle(), UIText.GitCloneWizard_failed, new Status(IStatus.ERROR, Activator.getPluginId(), 0, errorMessage, null)); return false; } final CloneOperation op = new CloneOperation(uri, allSelected, selectedBranches, workdir, branch, remoteName); importProject.setGitDir(op.getGitDir()); if (background) { final Job job = new Job(NLS.bind(UIText.GitCloneWizard_jobName, uri .toString())) { @Override protected IStatus run(final IProgressMonitor monitor) { try { op.run(monitor); return Status.OK_STATUS; } catch (InterruptedException e) { return Status.CANCEL_STATUS; } catch (InvocationTargetException e) { Throwable thr = e.getCause(); return new Status(IStatus.ERROR, Activator .getPluginId(), 0, thr.getMessage(), thr); } } }; job.setUser(true); job.schedule(); return true; } else { try { getContainer().run(true, true, op); return true; } catch (InterruptedException e) { MessageDialog.openInformation(getShell(), UIText.GitCloneWizard_CloneFailedHeading, UIText.GitCloneWizard_CloneCanceledMessage); return false; } catch (Exception e) { Activator.logError(UIText.GitCloneWizard_CloneFailedHeading, e); MessageDialog.openError(getShell(), UIText.GitCloneWizard_CloneFailedHeading, e.toString()); return false; } } }