Package org.eclipse.jgit.api

Examples of org.eclipse.jgit.api.AddCommand.call()


        for (Iterator<?> it = selection.iterator(); it.hasNext();) {
          CommitItem commitItem = (CommitItem) it.next();
          addCommand.addFilepattern(commitItem.path);
        }
        try {
          addCommand.call();
        } catch (Exception e) {
          Activator.logError(UIText.CommitDialog_ErrorAddingFiles, e);
        }
        for (Iterator<?> it = selection.iterator(); it.hasNext();) {
          CommitItem commitItem = (CommitItem) it.next();
View Full Code Here


                path.matchingFirstSegments(workTreePath))
            .setDevice(null).toString();
      addCommand.addFilepattern(repoRelativepath);
    }
    try {
      addCommand.call();
    } catch (GitAPIException e) {
      Activator.logError(UIText.AddToIndexCommand_addingFilesFailed,
          e);
    }
    return null;
View Full Code Here

                        pomPath = StringUtils.replace(pomPath,"\\","/");   
                    }
                   
                    add.addFilepattern(pomPath);
                }
                add.call();
                git.commit().setMessage(message).call();
            }
        }
        catch (GitAPIException e)
        {
View Full Code Here

    try {
      AddCommand adder = git.add();
      for (FileVersion fileVersion : fileVersions) {
        adder.addFilepattern(getPath(fileVersion.getFile(), repository));
      }
      adder.call();
      commit(git, String.format("[FitNesse] Updated files: %s.", formatFileVersions(fileVersions)), fileVersions[0].getAuthor());
    } catch (GitAPIException e) {
      throw new IOException("Unable to commit changes", e);
    }
    return VersionInfo.makeVersionInfo(fileVersions[0].getAuthor(), fileVersions[0].getLastModificationTime());
View Full Code Here

        for (String s : status.getUntracked()) {
          getLog().info("Adding file " + s);
          addCommand.addFilepattern(s);
        }

        addCommand.call();
      }

      git.commit().setAll(true).setMessage(versionDescription).call();

      masterRef = git.getRepository()
View Full Code Here

        if (!".git".equals(name)) {
          log("adding %s", name);
          add.addFilepattern(name);
        }
      }
      final DirCache index = add.call();
      final int cnt = index.getEntryCount();
      log("%d entries added", cnt);
      final String msg = "snapshot";
      final RevCommit head = git.commit().setMessage(msg).call();
View Full Code Here

        for (String s : status.getUntracked()) {
          getLog().info("Adding file " + s);
          addCommand.addFilepattern(s);
        }

        addCommand.call();
      }

      git.commit().setAll(true).setMessage(versionDescription).call();

      masterRef = git.getRepository()
View Full Code Here

                        pomPath = StringUtils.replace(pomPath,"\\","/");   
                    }
                   
                    add.addFilepattern(pomPath);
                }
                add.call();
                git.commit().setMessage(message).call();
            }
        }
        catch (GitAPIException e)
        {
View Full Code Here

                        pomPath = StringUtils.replace(pomPath,"\\","/");   
                    }
                   
                    add.addFilepattern(pomPath);
                }
                add.call();
                git.commit().setMessage(message).call();
            }
        }
        catch (GitAPIException e)
        {
View Full Code Here

                        pomPath = StringUtils.replace(pomPath, "\\", "/");
                    }

                    add.addFilepattern(pomPath);
                }
                add.call();
                git.commit().setMessage(message).call();
            }
        }
        catch (GitAPIException e)
        {
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.