aboutsummaryrefslogtreecommitdiffstats
path: root/ui-diff.c
Commit message (Expand)AuthorAgeFilesLines
* Add possibility to switch between unidiff and side-by-side-diff.•••A new config option side-by-side-diffs added, defaulting to 0, meaning unidiff. Also a query option (ss) is used toggle this. In the commit page you can switch between the two diff formats by clicking on the link on the "commit"-row, to the right of (patch). In the diff page you can switch by using the link at the start of the page. All commit-links and diff-links will remember the choice. Signed-off-by: Ragnar Ouchterlony <ragnar@lysator.liu.se> Signed-off-by: Lars Hjemli <hjemli@gmail.com> Ragnar Ouchterlony2009-09-161-2/+20
* First version of side-by-side diff.•••This constitutes the first prototype of a side-by-side diff. It is not possible to switch between unidiff and side-by-side diff at all at this stage. Signed-off-by: Ragnar Ouchterlony <ragnar@lysator.liu.se> Signed-off-by: Lars Hjemli <hjemli@gmail.com> Ragnar Ouchterlony2009-09-161-2/+13
* Handle binary files in diffs•••This teaches all diff-related operations (i.e. ui-log, ui-diff and ui-patch) how to handle binary files. Signed-off-by: Lars Hjemli <hjemli@gmail.com> Lars Hjemli2009-01-311-2/+24
* ui-diff: make diffstat header a link to the full diff•••When printing a path-filtered diff it wasn't obvious how to get back to the full diff (clicking the 'diff' tab would do this). Making the diffstat heading into a link seems to improve the usability. Signed-off-by: Lars Hjemli <hjemli@gmail.com> Lars Hjemli2008-09-231-1/+4
* ui-diff: fix links from diffstat•••The links in the diffstat is supposed to work as a filter for the diff, but this only worked when a single rev was supplied, i.e. the filtered diff was always against the parent of the specified rev. With this patch it is now possible to use the diffstat as a 'filter menu' for urls like http://hjemli.net/git/cgit/diff/?id=v0.7.2&id2=v0.7.1 Signed-off-by: Lars Hjemli <hjemli@gmail.com> Lars Hjemli2008-09-231-4/+2
* Include commit-id in link from diff-stat•••This fixes a regression created by fe1230dece81450004d02fa8a470f8dab8f7fdd9, and modifies a test to avoid future regressions. Signed-off-by: Lars Hjemli <hjemli@gmail.com> Lars Hjemli2008-05-181-0/+1
* ui-diff: remove test on object type•••By removing the test for commit objects it's now possible to specify a tag name for the id query-string parameter (it already worked for id2). Signed-off-by: Lars Hjemli <hjemli@gmail.com> Lars Hjemli2008-04-241-6/+0
* Integrate diffstat with diff•••This creates a generic diffstat function in ui-diff, which then is invoked from cgit_print_diff with the result that both commit and diff- view gets a diffstat. Signed-off-by: Lars Hjemli <hjemli@gmail.com> Lars Hjemli2008-04-241-0/+145
* Add ui-shared.h•••This is finally a proper headerfile for the shared ui-functions which used to reside in cgit.h Signed-off-by: Lars Hjemli <hjemli@gmail.com> Lars Hjemli2008-03-241-0/+1
* Introduce html.h•••All html-functions can be quite easily separated from the rest of cgit, so lets do it; the only issue was html_filemode which uses some git-defined macros so the function is moved into ui-shared.c::cgit_print_filemode(). Signed-off-by: Lars Hjemli <hjemli@gmail.com> Lars Hjemli2008-03-181-1/+1
* Introduce struct cgit_context•••This struct will hold all the cgit runtime information currently found in a multitude of global variables. The first cleanup removes all querystring-related variables. Signed-off-by: Lars Hjemli <hjemli@gmail.com> Lars Hjemli2008-02-161-3/+3
* Fix html error detected by test-suite•••Signed-off-by: Lars Hjemli <hjemli@gmail.com> Lars Hjemli2007-11-111-1/+1
* ui-diff: add links to pre- and postversion of blobs•••Each diff header now links to the old and new version of each file Signed-off-by: Lars Hjemli <hjemli@gmail.com> Lars Hjemli2007-10-011-16/+26
* Add prefix parameter to cgit_print_diff()•••This allows a diff to be restricted to the path prefix specified in the url. Signed-off-by: Lars Hjemli <hjemli@gmail.com> Lars Hjemli2007-10-011-2/+2
* Add prefix parameter to cgit_diff_tree()•••This paramter can be used to restrict a diff to the specified path prefix. Signed-off-by: Lars Hjemli <hjemli@gmail.com> Lars Hjemli2007-10-011-2/+1
* Merge branch 'jo/dirlink'•••* jo/dirlink: Rename dirlink to gitlink. Conflicts: ui-tree.c Signed-off-by: Lars Hjemli <hjemli@gmail.com> Lars Hjemli2007-09-031-4/+4
|\
| * Rename dirlink to gitlink.•••Git changed from dirlink to gitlink in 302b9282c9ddfcc704ca759bdc98c1d5f75eba2f. Signed-off-by: Jeffrey C. Ollie <jeff@ocjtech.us> Jeffrey C. Ollie2007-06-041-4/+4
* | Add cgit_diff_link()•••This adds a new function used to generate links to the diff page and uses it everywhere such links appear (expect for single files in the diffstat displayed on the commit page: this is now a link to the tree page). The updated diff-page now expects zero, one or two revision specifiers, in parameters head, id and id2. Id defaults to head unless otherwise specified, while head (as usual) defaults to repo.defbranch. If id2 isn't specified, it defaults to the first parent of id1. The most important change is of course that now all repo pages (summary, log, tree, commit and diff) has support for passing on the current branch and revision, i.e. the road is now open for a 'static' menu with links to all of these pages. Signed-off-by: Lars Hjemli <hjemli@gmail.com> Lars Hjemli2007-06-171-33/+31
* | ui-diff: close td/tr/table properly•••The previous commit fixed the diff-view when two trees where specified on the querystring (sha1/sha2) but made the generated html invalid when only a commit sha1 is specified. This fixes it. Signed-off-by: Lars Hjemli <hjemli@gmail.com> Lars Hjemli2007-06-061-0/+2
* | ui-diff: emit table/tr/td at better locations•••This fixes a bug which made the diff-link for each parent of a commit output a diff without correct styles. It also adds an error-message if the head commit specified on the querystring isn't a valid commit object. Signed-off-by: Lars Hjemli <hjemli@gmail.com> Lars Hjemli2007-06-051-9/+7
|/
* Fixed unexpected tags in html output.•••At least those that were catched by tidy. Signed-off-by: Lars Hjemli <hjemli@gmail.com> Ondrej Jirman2007-05-311-4/+5
* Don't die when diffing trees with subprojects•••The subprojects needs special handling, since they refer to objects which normally won't exist in the refering repository. Fix some extended header bugs and missing features while at it. Signed-off-by: Lars Hjemli <hjemli@gmail.com> Lars Hjemli2007-05-161-19/+43
* Add support for commitdiff via h parameter•••The commitdiff will be generated against the first parent, and the diff page also gets the benefit of repo.defbranch. Cleaned up some bad whitespace in cgit.h while at it. Signed-off-by: Lars Hjemli <hjemli@gmail.com> Lars Hjemli2007-05-161-1/+13
* ui-diff: show /dev/null as filename for add/delete•••The diff headers showed an invalid filename when a patch created or deleted a file. Fix it. Signed-off-by: Lars Hjemli <hjemli@gmail.com> Lars Hjemli2007-05-151-1/+4
* cgit.css: try to make diffs look a little bit nicer•••This makes the diffview look more like 'git-diff' in a terminal. Signed-off-by: Lars Hjemli <hjemli@gmail.com> Lars Hjemli2007-05-141-6/+26
* Add commitdiff between commit and each of it's parent•••A link is added next to each parent of a commit, leading to the new diff-functionality in ui-diff.c. Also added support for a path-parameter to filelevel diffs accessed via the diffstat. Signed-off-by: Lars Hjemli <hjemli@gmail.com> Lars Hjemli2007-05-131-4/+41
* Simplify ui-diff.c using the new file-level diff interface•••Signed-off-by: Lars Hjemli <hjemli@gmail.com> Lars Hjemli2007-05-131-86/+2
* Update to libgit 1.5.2-rc2•••Signed-off-by: Lars Hjemli <hjemli@gmail.com> Lars Hjemli2007-05-081-3/+2
* Layout updateLars Hjemli2007-02-211-1/+0
* Add basic diff view•••Finally, xdiff is used to show per-file diffs via commit view. Signed-off-by: Lars Hjemli <hjemli@gmail.com> Lars Hjemli2006-12-201-0/+131