1
0
Fork 0
mirror of https://github.com/git/git.git synced 2024-10-31 22:37:54 +01:00
git/diff.h
Junio C Hamano 81e50eabf0 [PATCH] The diff-raw format updates.
Update the diff-raw format as Linus and I discussed, except that
it does not use sequence of underscore '_' letters to express
nonexistence.  All '0' mode is used for that purpose instead.

The new diff-raw format can express rename/copy, and the earlier
restriction that -M and -C _must_ be used with the patch format
output is no longer necessary.  The patch makes -M and -C flags
independent of -p flag, so you need to say git-whatchanged -M -p
to get the diff/patch format.

Updated are both documentations and tests.

Signed-off-by: Junio C Hamano <junkio@cox.net>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-05-21 22:49:19 -07:00

41 lines
1,014 B
C

/*
* Copyright (C) 2005 Junio C Hamano
*/
#ifndef DIFF_H
#define DIFF_H
extern void diff_addremove(int addremove,
unsigned mode,
const unsigned char *sha1,
const char *base,
const char *path);
extern void diff_change(unsigned mode1, unsigned mode2,
const unsigned char *sha1,
const unsigned char *sha2,
const char *base, const char *path);
extern void diff_guif(unsigned mode1,
unsigned mode2,
const unsigned char *sha1,
const unsigned char *sha2,
const char *path1,
const char *path2);
extern void diff_unmerge(const char *path);
extern int diff_scoreopt_parse(const char *opt);
#define DIFF_FORMAT_HUMAN 0
#define DIFF_FORMAT_MACHINE 1
#define DIFF_FORMAT_PATCH 2
extern void diff_setup(int reverse, int diff_output_style);
extern void diff_detect_rename(int, int);
extern void diff_pickaxe(const char *);
extern int diff_queue_is_empty(void);
extern void diff_flush(const char **, int);
#endif /* DIFF_H */