Allow more than true/false to attributes.

This allows you to define three values (and possibly more) to
each attribute: true, false, and unset.

Typically the handlers that notice and act on attribute values
treat "unset" attribute to mean "do your default thing"
(e.g. crlf that is unset would trigger "guess from contents"),
so being able to override a setting to an unset state is
actually useful.

 - If you want to set the attribute value to true, have an entry
   in .gitattributes file that mentions the attribute name; e.g.

	*.o	binary

 - If you want to set the attribute value explicitly to false,
   use '-'; e.g.

	*.a	-diff

 - If you want to make the attribute value _unset_, perhaps to
   override an earlier entry, use '!'; e.g.

	*.a	-diff
	c.i.a	!diff

This also allows string values to attributes, with the natural
syntax:

	attrname=attrvalue

but you cannot use it, as nobody takes notice and acts on
it yet.

Signed-off-by: Junio C Hamano <junkio@cox.net>
5 files changed
tree: 4655f5942a377ce8d6fa99ec2c6044071abcac36
  1. arm/
  2. compat/
  3. contrib/
  4. Documentation/
  5. git-gui/
  6. gitweb/
  7. mozilla-sha1/
  8. perl/
  9. ppc/
  10. t/
  11. templates/
  12. xdiff/
  13. .gitignore
  14. .mailmap
  15. alloc.c
  16. archive-tar.c
  17. archive-zip.c
  18. archive.h
  19. attr.c
  20. attr.h
  21. base85.c
  22. blob.c
  23. blob.h
  24. builtin-add.c
  25. builtin-annotate.c
  26. builtin-apply.c
  27. builtin-archive.c
  28. builtin-blame.c
  29. builtin-branch.c
  30. builtin-bundle.c
  31. builtin-cat-file.c
  32. builtin-check-attr.c
  33. builtin-check-ref-format.c
  34. builtin-checkout-index.c
  35. builtin-commit-tree.c
  36. builtin-config.c
  37. builtin-count-objects.c
  38. builtin-describe.c
  39. builtin-diff-files.c
  40. builtin-diff-index.c
  41. builtin-diff-tree.c
  42. builtin-diff.c
  43. builtin-fetch--tool.c
  44. builtin-fmt-merge-msg.c
  45. builtin-for-each-ref.c
  46. builtin-fsck.c
  47. builtin-gc.c
  48. builtin-grep.c
  49. builtin-init-db.c
  50. builtin-log.c
  51. builtin-ls-files.c
  52. builtin-ls-tree.c
  53. builtin-mailinfo.c
  54. builtin-mailsplit.c
  55. builtin-merge-base.c
  56. builtin-merge-file.c
  57. builtin-mv.c
  58. builtin-name-rev.c
  59. builtin-pack-objects.c
  60. builtin-pack-refs.c
  61. builtin-prune-packed.c
  62. builtin-prune.c
  63. builtin-push.c
  64. builtin-read-tree.c
  65. builtin-reflog.c
  66. builtin-rerere.c
  67. builtin-rev-list.c
  68. builtin-rev-parse.c
  69. builtin-revert.c
  70. builtin-rm.c
  71. builtin-runstatus.c
  72. builtin-shortlog.c
  73. builtin-show-branch.c
  74. builtin-show-ref.c
  75. builtin-stripspace.c
  76. builtin-symbolic-ref.c
  77. builtin-tar-tree.c
  78. builtin-unpack-objects.c
  79. builtin-update-index.c
  80. builtin-update-ref.c
  81. builtin-upload-archive.c
  82. builtin-verify-pack.c
  83. builtin-write-tree.c
  84. builtin.h
  85. cache-tree.c
  86. cache-tree.h
  87. cache.h
  88. check-builtins.sh
  89. check-racy.c
  90. color.c
  91. color.h
  92. combine-diff.c
  93. commit.c
  94. commit.h
  95. config.c
  96. config.mak.in
  97. configure.ac
  98. connect.c
  99. convert-objects.c
  100. convert.c
  101. copy.c
  102. COPYING
  103. csum-file.c
  104. csum-file.h
  105. ctype.c
  106. daemon.c
  107. date.c
  108. delta.h
  109. diff-delta.c
  110. diff-lib.c
  111. diff.c
  112. diff.h
  113. diffcore-break.c
  114. diffcore-delta.c
  115. diffcore-order.c
  116. diffcore-pickaxe.c
  117. diffcore-rename.c
  118. diffcore.h
  119. dir.c
  120. dir.h
  121. dump-cache-tree.c
  122. entry.c
  123. environment.c
  124. exec_cmd.c
  125. exec_cmd.h
  126. fast-import.c
  127. fetch-pack.c
  128. fetch.c
  129. fetch.h
  130. generate-cmdlist.sh
  131. git-add--interactive.perl
  132. git-am.sh
  133. git-applymbox.sh
  134. git-applypatch.sh
  135. git-archimport.perl
  136. git-bisect.sh
  137. git-checkout.sh
  138. git-clean.sh
  139. git-clone.sh
  140. git-commit.sh
  141. git-compat-util.h
  142. git-cvsexportcommit.perl
  143. git-cvsimport.perl
  144. git-cvsserver.perl
  145. git-fetch.sh
  146. git-instaweb.sh
  147. git-lost-found.sh
  148. git-ls-remote.sh
  149. git-merge-octopus.sh
  150. git-merge-one-file.sh
  151. git-merge-ours.sh
  152. git-merge-resolve.sh
  153. git-merge-stupid.sh
  154. git-merge.sh
  155. git-mergetool.sh
  156. git-p4import.py
  157. git-parse-remote.sh
  158. git-pull.sh
  159. git-quiltimport.sh
  160. git-rebase.sh
  161. git-relink.perl
  162. git-remote.perl
  163. git-repack.sh
  164. git-request-pull.sh
  165. git-reset.sh
  166. git-send-email.perl
  167. git-sh-setup.sh
  168. git-svn.perl
  169. git-svnimport.perl
  170. git-tag.sh
  171. git-verify-tag.sh
  172. GIT-VERSION-GEN
  173. git.c
  174. git.spec.in
  175. gitk
  176. grep.c
  177. grep.h
  178. hash-object.c
  179. help.c
  180. http-fetch.c
  181. http-push.c
  182. http.c
  183. http.h
  184. ident.c
  185. imap-send.c
  186. index-pack.c
  187. INSTALL
  188. interpolate.c
  189. interpolate.h
  190. list-objects.c
  191. list-objects.h
  192. local-fetch.c
  193. lockfile.c
  194. log-tree.c
  195. log-tree.h
  196. Makefile
  197. match-trees.c
  198. merge-file.c
  199. merge-index.c
  200. merge-recursive.c
  201. merge-tree.c
  202. mktag.c
  203. mktree.c
  204. object-refs.c
  205. object.c
  206. object.h
  207. pack-check.c
  208. pack-redundant.c
  209. pack.h
  210. pager.c
  211. patch-delta.c
  212. patch-id.c
  213. patch-ids.c
  214. patch-ids.h
  215. path-list.c
  216. path-list.h
  217. path.c
  218. peek-remote.c
  219. pkt-line.c
  220. pkt-line.h
  221. quote.c
  222. quote.h
  223. reachable.c
  224. reachable.h
  225. read-cache.c
  226. README
  227. receive-pack.c
  228. reflog-walk.c
  229. reflog-walk.h
  230. refs.c
  231. refs.h
  232. revision.c
  233. revision.h
  234. rsh.c
  235. rsh.h
  236. run-command.c
  237. run-command.h
  238. send-pack.c
  239. server-info.c
  240. setup.c
  241. sha1_file.c
  242. sha1_name.c
  243. shallow.c
  244. shell.c
  245. show-index.c
  246. sideband.c
  247. sideband.h
  248. ssh-fetch.c
  249. ssh-pull.c
  250. ssh-push.c
  251. ssh-upload.c
  252. strbuf.c
  253. strbuf.h
  254. tag.c
  255. tag.h
  256. tar.h
  257. test-chmtime.c
  258. test-date.c
  259. test-delta.c
  260. test-match-trees.c
  261. test-sha1.c
  262. test-sha1.sh
  263. trace.c
  264. tree-diff.c
  265. tree-walk.c
  266. tree-walk.h
  267. tree.c
  268. tree.h
  269. unpack-file.c
  270. unpack-trees.c
  271. unpack-trees.h
  272. update-server-info.c
  273. upload-pack.c
  274. usage.c
  275. utf8.c
  276. utf8.h
  277. var.c
  278. write_or_die.c
  279. wt-status.c
  280. wt-status.h
  281. xdiff-interface.c
  282. xdiff-interface.h