Package org.eclipse.egit.core.op

Examples of org.eclipse.egit.core.op.ConnectProviderOperation.execute()


  }

  private void connectProject(IProject project, File gitDir) throws CoreException {
    ConnectProviderOperation operation = new ConnectProviderOperation(
        project.getProject(), gitDir);
    operation.execute(null);
  }

  private static String createProjectReference(IPath repoPath, String branch, String projectPath) {
    return "1.0," + createUrl(repoPath) + "," + branch + "," + projectPath;
  }
View Full Code Here


  }

  private void connectProject(IProject p) throws CoreException {
    final ConnectProviderOperation operation = new ConnectProviderOperation(
        p, gitDir);
    operation.execute(null);
  }

  private List<Entry> walkTree() throws IOException {
    TreeWalk treeWalk = new TreeWalk(repository);
    ContainerTreeIterator tree = new ContainerTreeIterator(repository, project.getProject());
View Full Code Here

  @Test
  public void testGetProjects() throws Exception {
    ConnectProviderOperation operation = new ConnectProviderOperation(
        project.getProject(), gitDir);
    operation.execute(null);
    IProject[] projects = ProjectUtil.getProjects(repository
        .getRepository());
    assertEquals(1, projects.length);
    IProject p = projects[0];
    assertEquals("Project-1", p.getDescription().getName());
View Full Code Here

    fileWriter.write("aaaaaaaaaaa");
    fileWriter.close();

    final ConnectProviderOperation operation = new ConnectProviderOperation(
        project.getProject(), gitDir);
    operation.execute(null);
  }

  @Test
  public void testFileTreeToContainerAdaptation() throws IOException {
    final IWorkspaceRoot root = project.getProject().getWorkspace()
View Full Code Here

    singleProjectRepo.create();

    // Repository must be mapped in order to test the GitFileHistory
    Activator.getDefault().getRepositoryUtil().addConfiguredRepository(singleProjectGitDir);
    ConnectProviderOperation connectOp = new ConnectProviderOperation(proj, singleProjectGitDir);
    connectOp.execute(progress);

    try {
      IFile file = proj.getFile("file");
      file.create(new ByteArrayInputStream("data".getBytes("UTF-8")), 0,
          progress);
View Full Code Here

    git.commit().setAuthor(jauthor).setCommitter(jcommitter)
        .setMessage("Modified").call();

    ConnectProviderOperation operation = new ConnectProviderOperation(
        project.getProject(), gitDir);
    operation.execute(null);
  }

  private File createFile(String name, String content) throws IOException {
    File f = new File(workDir, name);
    Writer fileWriter = null;
View Full Code Here

  }

  private void connect(IProject p) throws CoreException {
    ConnectProviderOperation operation = new ConnectProviderOperation(p,
        gitDir);
    operation.execute(null);
  }
}
View Full Code Here

  @Test
  public void testNoRepository() throws CoreException {

    ConnectProviderOperation operation = new ConnectProviderOperation(
        project.getProject(), new File("../..", Constants.DOT_GIT));
    operation.execute(null);

    assertFalse(RepositoryProvider.isShared(project.getProject()));
    assertFalse(gitDir.exists());
  }
View Full Code Here

    Repository repository = FileRepositoryBuilder.create(gitDir);
    repository.create();
    repository.close();
    ConnectProviderOperation operation = new ConnectProviderOperation(
        project.getProject(), gitDir);
    operation.execute(null);

    assertTrue(RepositoryProvider.isShared(project.getProject()));

    assertTrue(gitDir.exists());
  }
View Full Code Here

    repository.create();
    repository.close();
    project.setBinFolderDerived();
    ConnectProviderOperation operation = new ConnectProviderOperation(
        project.getProject(), gitDir);
    operation.execute(null);

    assertTrue(RepositoryProvider.isShared(project.getProject()));
    Job.getJobManager().join(JobFamilies.AUTO_IGNORE, null);

    IPath binPath = project.getProject().getLocation().append("bin");
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.