diff --git a/archive.c b/archive.c
index 7a32c19d3ca8043f3ca22dadfdbc60dbbb747d59..6502b76ef10a182e9d9f0e60ad926c55a31a737a 100644 (file)
--- a/archive.c
+++ b/archive.c
return buffer;
}
+int is_archive_path_ignored(const char *path)
+{
+ static struct git_attr *attr_export_ignore;
+ struct git_attr_check check[1];
+
+ if (!attr_export_ignore)
+ attr_export_ignore = git_attr("export-ignore", 13);
+
+ check[0].attr = attr_export_ignore;
+ if (git_checkattr(path, ARRAY_SIZE(check), check))
+ return 0;
+ return ATTR_TRUE(check[0].value);
+}