diff options
author | Junio C Hamano <junkio@cox.net> | 2006-04-15 03:16:46 -0700 |
---|---|---|
committer | Junio C Hamano <junkio@cox.net> | 2006-04-15 03:24:33 -0700 |
commit | f4235f8b2ef875b85ead74ffa199d827f9ee9d8d (patch) | |
tree | 9805f85029ac2c0a392c00e8a2e7a7be1e252933 /log-tree.h | |
parent | diff-tree: typefix. (diff) | |
download | tgif-f4235f8b2ef875b85ead74ffa199d827f9ee9d8d.tar.xz |
Extract "log [diff options]" parser out.
Merging of the log-tree-opt structure with rev-info structure
did not work out very well and it broke things that did not want
diff options and/or rev options.
This is an alternative approach to define a combined interface
that can be used by commands that wants both. The use of it is
opt-in to reduce the risk of breaking existing programs.
We might want to slurp "setup_revisions() places things in
pending objects list" part from Linus's earlier attempt.
Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'log-tree.h')
-rw-r--r-- | log-tree.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/log-tree.h b/log-tree.h index da166c6f2c..50cbfb3012 100644 --- a/log-tree.h +++ b/log-tree.h @@ -1,6 +1,8 @@ #ifndef LOG_TREE_H #define LOG_TREE_H +#include "revision.h" + struct log_tree_opt { struct diff_options diffopt; int show_root_diff; @@ -20,4 +22,16 @@ int log_tree_diff_flush(struct log_tree_opt *); int log_tree_commit(struct log_tree_opt *, struct commit *); int log_tree_opt_parse(struct log_tree_opt *, const char **, int); +struct whatchanged_opt { + struct rev_info revopt; + struct log_tree_opt logopt; + enum cmit_fmt commit_format; + int abbrev; + int abbrev_commit; + int do_diff; + int full_diff; +}; + +int parse_whatchanged_opt(int, const char **, struct whatchanged_opt *); + #endif |