summaryrefslogtreecommitdiff
path: root/attr.c
diff options
context:
space:
mode:
authorJunio C Hamano <junkio@cox.net>2007-04-12 23:05:29 -0700
committerJunio C Hamano <junkio@cox.net>2007-04-14 08:57:06 -0700
commit8c701249d2257699c19822b528c101668abc55b9 (patch)
treef53d3cf1957b792b456f63517df04e8529d99448 /attr.c
parent35ebfd6a0cd71795c4fa510b99e55ad89fb654f1 (diff)
downloadgit-8c701249d2257699c19822b528c101668abc55b9.tar.gz
Teach 'diff' about 'diff' attribute.
This makes paths that explicitly unset 'diff' attribute not to produce "textual" diffs from 'git-diff' family. Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'attr.c')
-rw-r--r--attr.c18
1 files changed, 0 insertions, 18 deletions
diff --git a/attr.c b/attr.c
index ed4db01a89..7435d927a9 100644
--- a/attr.c
+++ b/attr.c
@@ -378,21 +378,3 @@ int git_checkattr(const char *path, int num, struct git_attr_check *check)
rem = fill(path, pathlen, stk, check, num, rem);
return 0;
}
-
-static void setup_binary_check(struct git_attr_check *check)
-{
- static struct git_attr *attr_binary;
-
- if (!attr_binary)
- attr_binary = git_attr("binary", 6);
- check->attr = attr_binary;
-}
-
-int git_path_is_binary(const char *path)
-{
- struct git_attr_check attr_binary_check;
-
- setup_binary_check(&attr_binary_check);
- return (!git_checkattr(path, 1, &attr_binary_check) &&
- (0 < attr_binary_check.isset));
-}