Package org.eclipse.jgit.api

Examples of org.eclipse.jgit.api.SubmoduleInitCommand


    String update = "rebase";
    modulesConfig.setString(ConfigConstants.CONFIG_SUBMODULE_SECTION, path,
        ConfigConstants.CONFIG_KEY_UPDATE, update);
    modulesConfig.save();

    SubmoduleInitCommand command = new SubmoduleInitCommand(db);
    Collection<String> modules = command.call();
    assertNotNull(modules);
    assertEquals(1, modules.size());
    assertEquals(path, modules.iterator().next());

    generator = SubmoduleWalk.forIndex(db);
View Full Code Here


    String update = "rebase";
    modulesConfig.setString(ConfigConstants.CONFIG_SUBMODULE_SECTION, path,
        ConfigConstants.CONFIG_KEY_UPDATE, update);
    modulesConfig.save();

    SubmoduleInitCommand command = new SubmoduleInitCommand(db);
    Collection<String> modules = command.call();
    assertNotNull(modules);
    assertEquals(1, modules.size());
    assertEquals(path, modules.iterator().next());

    generator = SubmoduleWalk.forIndex(db);
View Full Code Here

    String update = "rebase";
    modulesConfig.setString(ConfigConstants.CONFIG_SUBMODULE_SECTION, path,
        ConfigConstants.CONFIG_KEY_UPDATE, update);
    modulesConfig.save();

    SubmoduleInitCommand command = new SubmoduleInitCommand(db);
    Collection<String> modules = command.call();
    assertNotNull(modules);
    assertEquals(1, modules.size());
    assertEquals(path, modules.iterator().next());

    generator = SubmoduleWalk.forIndex(db);
View Full Code Here

    String update = "rebase";
    modulesConfig.setString(ConfigConstants.CONFIG_SUBMODULE_SECTION, path,
        ConfigConstants.CONFIG_KEY_UPDATE, update);
    modulesConfig.save();

    SubmoduleInitCommand command = new SubmoduleInitCommand(db);
    Collection<String> modules = command.call();
    assertNotNull(modules);
    assertEquals(1, modules.size());
    assertEquals(path, modules.iterator().next());

    generator = SubmoduleWalk.forIndex(db);
View Full Code Here

    modulesConfig.setString(ConfigConstants.CONFIG_SUBMODULE_SECTION, path,
        ConfigConstants.CONFIG_KEY_URL, url);
    modulesConfig.save();

    try {
      new SubmoduleInitCommand(db).call();
      fail("Exception not thrown");
    } catch (JGitInternalException e) {
      assertTrue(e.getCause() instanceof IOException);
    }
  }
View Full Code Here

*/
public class SubmoduleInitTest extends RepositoryTestCase {

  @Test
  public void repositoryWithNoSubmodules() throws GitAPIException {
    SubmoduleInitCommand command = new SubmoduleInitCommand(db);
    Collection<String> modules = command.call();
    assertNotNull(modules);
    assertTrue(modules.isEmpty());
  }
View Full Code Here

    String update = "rebase";
    modulesConfig.setString(ConfigConstants.CONFIG_SUBMODULE_SECTION, path,
        ConfigConstants.CONFIG_KEY_UPDATE, update);
    modulesConfig.save();

    SubmoduleInitCommand command = new SubmoduleInitCommand(db);
    Collection<String> modules = command.call();
    assertNotNull(modules);
    assertEquals(1, modules.size());
    assertEquals(path, modules.iterator().next());

    generator = SubmoduleWalk.forIndex(db);
View Full Code Here

        pm.beginTask("", 3); //$NON-NLS-1$
        Git git = Git.wrap(repository);

        Collection<String> updated = null;
        try {
          SubmoduleInitCommand init = git.submoduleInit();
          for (String path : paths)
            init.addPath(path);
          init.call();
          pm.worked(1);

          SubmoduleUpdateCommand update = git.submoduleUpdate();
          for (String path : paths)
            update.addPath(path);
View Full Code Here

TOP

Related Classes of org.eclipse.jgit.api.SubmoduleInitCommand

Copyright © 2018 www.massapicom. 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.