Source:
<code>private void connectProject(Entry<IProject, File> entry, MultiStatus ms, IProgressMonitor monitor) throws CoreException { IProject project = entry.getKey(); String taskName = NLS.bind( CoreText.ConnectProviderOperation_ConnectingProject, project.getName()); SubMonitor subMon = SubMonitor.convert(monitor, taskName, 100); if (GitTraceLocation.CORE.isActive()) { GitTraceLocation.getTrace() .trace(GitTraceLocation.CORE.getLocation(), taskName); } RepositoryFinder finder = new RepositoryFinder(project); finder.setFindInChildren(false); Collection<RepositoryMapping> repos = finder.find(subMon.newChild(50)); if (repos.isEmpty()) { ms.add(Activator.error(NLS.bind( CoreText.ConnectProviderOperation_NoRepositoriesError, project.getName()), null)); return; } RepositoryMapping actualMapping = findActualRepository(repos, entry.getValue()); if (actualMapping == null) { ms.add(Activator.error(NLS.bind( CoreText.ConnectProviderOperation_UnexpectedRepositoryError, new Object[] { project.getName(), entry.getValue().toString(), repos.toString() }), null)); return; } GitProjectData projectData = new GitProjectData(project); try { projectData.setRepositoryMappings(Arrays.asList(actualMapping)); projectData.store(); GitProjectData.add(project, projectData); } catch (CoreException ce) { ms.add(ce.getStatus()); deleteGitProvider(ms, project); return; } catch (RuntimeException ce) { ms.add(Activator.error(ce.getMessage(), ce)); deleteGitProvider(ms, project); return; } RepositoryProvider.map(project, GitProvider.ID); if (refreshResources) { project.refreshLocal(IResource.DEPTH_INFINITE, subMon.newChild(40)); } else { subMon.worked(40); } autoIgnoreDerivedResources(project, <START> subMon); <END> }</code><technical_language>subMon.newChild(10)</technical_language>

Target:
private void connectProject(Entry<IProject, File> entry, MultiStatus ms, IProgressMonitor monitor) throws CoreException { IProject project = entry.getKey(); String taskName = NLS.bind( CoreText.ConnectProviderOperation_ConnectingProject, project.getName()); SubMonitor subMon = SubMonitor.convert(monitor, taskName, 100); if (GitTraceLocation.CORE.isActive()) { GitTraceLocation.getTrace() .trace(GitTraceLocation.CORE.getLocation(), taskName); } RepositoryFinder finder = new RepositoryFinder(project); finder.setFindInChildren(false); Collection<RepositoryMapping> repos = finder.find(subMon.newChild(50)); if (repos.isEmpty()) { ms.add(Activator.error(NLS.bind( CoreText.ConnectProviderOperation_NoRepositoriesError, project.getName()), null)); return; } RepositoryMapping actualMapping = findActualRepository(repos, entry.getValue()); if (actualMapping == null) { ms.add(Activator.error(NLS.bind( CoreText.ConnectProviderOperation_UnexpectedRepositoryError, new Object[] { project.getName(), entry.getValue().toString(), repos.toString() }), null)); return; } GitProjectData projectData = new GitProjectData(project); try { projectData.setRepositoryMappings(Arrays.asList(actualMapping)); projectData.store(); GitProjectData.add(project, projectData); } catch (CoreException ce) { ms.add(ce.getStatus()); deleteGitProvider(ms, project); return; } catch (RuntimeException ce) { ms.add(Activator.error(ce.getMessage(), ce)); deleteGitProvider(ms, project); return; } RepositoryProvider.map(project, GitProvider.ID); if (refreshResources) { project.refreshLocal(IResource.DEPTH_INFINITE, subMon.newChild(40)); } else { subMon.worked(40); } autoIgnoreDerivedResources(project, subMon.newChild(10)); }