summaryrefslogtreecommitdiff
path: root/Documentation/gitattributes.txt
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2007-09-10 07:14:50 (GMT)
committerJunio C Hamano <gitster@pobox.com>2007-09-10 07:14:50 (GMT)
commit6972ab7ae10a205bbc05b98408a36403915a9c39 (patch)
tree755ab51db764a7d35e9546eb30a5d4440291b014 /Documentation/gitattributes.txt
parent9784c5c53e0765bc9a0c973ab10aaf0734d535c3 (diff)
parent20fbfd869fe8faae0ce4573b60b540024db7385d (diff)
downloadgit-6972ab7ae10a205bbc05b98408a36403915a9c39.zip
git-6972ab7ae10a205bbc05b98408a36403915a9c39.tar.gz
git-6972ab7ae10a205bbc05b98408a36403915a9c39.tar.bz2
Merge branch 'rs/archive'
* rs/archive: archive - leakfix for format_subst() Define NO_MEMMEM on Darwin as it lacks the function archive: rename attribute specfile to export-subst archive: specfile syntax change: "$Format:%PLCHLDR$" instead of just "%PLCHLDR" (take 2) add memmem() Remove unused function convert_sha1_file() archive: specfile support (--pretty=format: in archive files) Export format_commit_message()
Diffstat (limited to 'Documentation/gitattributes.txt')
-rw-r--r--Documentation/gitattributes.txt17
1 files changed, 17 insertions, 0 deletions
diff --git a/Documentation/gitattributes.txt b/Documentation/gitattributes.txt
index 46f9d59..d0e951e 100644
--- a/Documentation/gitattributes.txt
+++ b/Documentation/gitattributes.txt
@@ -421,6 +421,23 @@ frotz unspecified
----------------------------------------------------------------
+Creating an archive
+~~~~~~~~~~~~~~~~~~~
+
+`export-subst`
+^^^^^^^^^^^^^^
+
+If the attribute `export-subst` is set for a file then git will expand
+several placeholders when adding this file to an archive. The
+expansion depends on the availability of a commit ID, i.e. if
+gitlink:git-archive[1] has been given a tree instead of a commit or a
+tag then no replacement will be done. The placeholders are the same
+as those for the option `--pretty=format:` of gitlink:git-log[1],
+except that they need to be wrapped like this: `$Format:PLACEHOLDERS$`
+in the file. E.g. the string `$Format:%H$` will be replaced by the
+commit hash.
+
+
GIT
---
Part of the gitlink:git[7] suite