| Summary: | [compare] More generic Diff JSON representation | ||
|---|---|---|---|
| Product: | [ECD] Orion | Reporter: | Szymon Brandys <Szymon.Brandys> |
| Component: | Client | Assignee: | Project Inbox <orion.client-inbox> |
| Status: | RESOLVED FIXED | QA Contact: | |
| Severity: | normal | ||
| Priority: | P3 | CC: | libingw, tomasz.zarna |
| Version: | unspecified | ||
| Target Milestone: | 0.3 | ||
| Hardware: | PC | ||
| OS: | Windows 7 | ||
| Whiteboard: | |||
(In reply to comment #0) > I would replace the 'Git' key with 'Diff' or just move Base, Old, New to top. I'm up for the latter. The representation changed to: { "Type": "Diff", "Location" : "...", "Base" : "...", "New" : "...", "Old" : "..." } with http://git.eclipse.org/c/orion/org.eclipse.orion.server.git/commit/?id=617fd5ac2c037e1b023076bc4e414549da77bc65.
Compare aligned to this change. |
I noticed that the compare framework looks for the Git key in Diff JSONs. Since the compare may be used with various diff providers, we should use more generic name for this particular key. So far the diff representations expected by the compare looks like this: --QBsq4sftABAQAaNRbB60wA Content-Type: application/json; charset=UTF-8 {"Git": {"Base":"http://localhost:8080/gitapi/index/file/z/a.txt", "DiffLocation":"http://localhost:8080/gitapi/diff/Default/file/z/a.txt", "New":"http://localhost:8080/file/z/a.txt", "Old":"http://localhost:8080/gitapi/index/file/z/a.txt"} } --QBsq4sftABAQAaNRbB60wA Content-Type: plain/text diff --git a/a.txt b/a.txt index 8318c86..4c5893c 100644 --- a/a.txt . . . I would replace the 'Git' key with 'Diff' or just move Base, Old, New to top.