Commit Graph

13 Commits

Author SHA1 Message Date
Russell Belfer
3b5f795446 Create git_diff_line and extend git_diff_hunk
Instead of having functions with so very many parameters to pass
hunk and line data, this takes the existing git_diff_hunk struct
and extends it with more hunk data, plus adds a git_diff_line.
Those structs are used to pass back hunk and line data instead of
the old APIs that took tons of parameters.

Some work that was previously only being done for git_diff_patch
creation (scanning the diff content for exact line counts) is now
done for all callbacks, but the performance difference should not
be noticable.
2013-10-21 13:42:42 -07:00
Russell Belfer
10672e3e45 Diff API cleanup
This lays groundwork for separating formatting options from diff
creation options.  This groups the formatting flags separately
from the diff list creation flags and reorders the options.  This
also tweaks some APIs to further separate code that uses patches
from code that just looks at git_diffs.
2013-10-15 15:10:07 -07:00
Russell Belfer
3ff1d12373 Rename diff objects and split patch.h
This makes no functional change to diff but renames a couple of
the objects and splits the new git_patch (formerly git_diff_patch)
into a new header file.
2013-10-11 14:51:54 -07:00
Brendan Macmillan
c3ae047361 Fix -n bug; default to all ancestors 2013-07-27 05:34:49 +10:00
Russell Belfer
bc6f0839eb Add a bunch more features to log example 2013-07-10 20:50:32 +02:00
Russell Belfer
a8b5f116bc Fix example/log.c pathspec handling of merges
This fixes the way the example log program decides if a merge
commit should be shown when a pathspec is given.  Also makes it
easier to use the pathspec API to just check "does a tree match
anything in the pathspec" without allocating a match list.
2013-07-10 20:50:32 +02:00
Russell Belfer
733c4f3aca more examples/log.c bug fixing 2013-07-10 20:50:32 +02:00
Russell Belfer
5a169711fa fix bug with order args and no revision 2013-07-10 20:50:32 +02:00
Russell Belfer
2b3bd8ecd8 Fix example/log.c minor diffs with git log 2013-07-10 20:50:32 +02:00
Russell Belfer
f44c4fa108 Add basic commit formatting to log output 2013-07-10 20:50:32 +02:00
Russell Belfer
d0628e2fee More progress on log example 2013-07-10 20:50:32 +02:00
Russell Belfer
0d44d3dc84 Extending log example code
This adds more command line processing to the example version of
log.  In particular, this adds the funky command line processing
that allows an arbitrary series of revisions followed by an
arbitrary number of paths and/or glob patterns.

The actual logging part still isn't implemented.
2013-07-10 20:50:32 +02:00
Russell Belfer
d39fff3648 Basic framework for log command 2013-07-10 20:50:31 +02:00