1/* 2 * Copyright (C) 2005 Junio C Hamano 3 */ 4#ifndef DIFF_H 5#define DIFF_H 6 7externvoiddiff_addremove(int addremove, 8unsigned mode, 9const unsigned char*sha1, 10const char*base, 11const char*path); 12 13externvoiddiff_change(unsigned mode1,unsigned mode2, 14const unsigned char*sha1, 15const unsigned char*sha2, 16const char*base,const char*path); 17 18externvoiddiff_unmerge(const char*path); 19 20/* These are for diff-helper */ 21 22struct diff_spec { 23unsigned char blob_sha1[20]; 24unsigned short mode;/* file mode */ 25unsigned sha1_valid :1;/* if true, use blob_sha1 and trust mode; 26 * however with a NULL SHA1, read them 27 * from the file system. 28 * if false, use the name and read mode from 29 * the filesystem. 30 */ 31unsigned file_valid :1;/* if false the file does not even exist */ 32}; 33 34externvoidrun_external_diff(const char*name, 35struct diff_spec *,struct diff_spec *); 36 37#endif/* DIFF_H */