From fddcb7b82ff45dc9e08bab26bbfe7a2d2e8ca20f Mon Sep 17 00:00:00 2001 From: Baptiste Daroussin Date: Thu, 20 Apr 2017 14:22:33 +0000 Subject: Implement a basic --changed-group-format etcupdate(8) requires that option, while GNU diff supports many more variation of that options, their behaviour beside the simple verion implemented here are quite inconsistent as such I do not plan to implement those. The only special keyword supported by this implementation are: %< and %> %= is not implemented as the documentation of GNU diff says: common lines, but it actually when tested print the changes from the first file --- usr.bin/diff/diff.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'usr.bin/diff/diff.h') diff --git a/usr.bin/diff/diff.h b/usr.bin/diff/diff.h index f70bb96102a4..87452058220f 100644 --- a/usr.bin/diff/diff.h +++ b/usr.bin/diff/diff.h @@ -47,6 +47,7 @@ #define D_NREVERSE 5 /* Reverse ed script with numbered lines and no trailing . */ #define D_BRIEF 6 /* Say if the files differ */ +#define D_GFORMAT 7 /* Diff with defined changed group format */ /* * Output flags @@ -87,6 +88,7 @@ extern int lflag, Nflag, Pflag, rflag, sflag, Tflag, cflag; extern int diff_format, diff_context, status, ignore_file_case; extern int tabsize; extern char *start, *ifdefname, *diffargs, *label[2], *ignore_pats; +extern char *group_format; extern struct stat stb1, stb2; extern struct excludes *excludes_list; extern regex_t ignore_re; -- cgit v1.2.3