Package org.eclipse.jgit.api

Examples of org.eclipse.jgit.api.ApplyResult


      Git git = new Git(db);
      ApplyCommand applyCommand = git.apply();
      applyCommand.setPatch(IOUtilities.toInputStream(patch));
      // TODO: ignore all errors for now, see bug 366008
      try {
        ApplyResult applyResult = applyCommand.call();
        JSONObject resp = new JSONObject();
        JSONArray modifiedFieles = new JSONArray();
        for (File file : applyResult.getUpdatedFiles()) {
          modifiedFieles.put(stripGlobalPaths(db, file.getAbsolutePath()));
        }
        resp.put("modifiedFieles", modifiedFieles);
        return statusHandler.handleRequest(request, response, new ServerStatus(Status.OK_STATUS, HttpServletResponse.SC_OK, resp));
        // OrionServlet.writeJSONResponse(request, response, toJSON(applyResult));
View Full Code Here

TOP

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

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.