[PATCH] Documentation/git.txt: Mention unsupported use of --git-dir/GIT_DIR

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



We don't support using --git-dir/GIT_DIR to change the name of the
.git directory, so make this clear in the documentation.

Signed-off-by: Julian Phillips <julian@xxxxxxxxxxxxxxxxx>
---
On Tue, 25 Mar 2008, Julian Phillips wrote:

> On Mon, 24 Mar 2008, Junio C Hamano wrote:
>
>>  Junio C Hamano <gitster@xxxxxxxxx> writes:
>> 
>> > >  Well, git won't allow .git as a element anywhere in the path, when
we
>> > >  should only care about the _first_ one - and also, if you use
>> > >  --git-dir=banana then we still check for '.git' ... oops.
>> > 
>> >  That's not how git-dir is supposed to used, so there is no oops.
>> 
>>  The only purpose of git-dir is to have $GIT_DIR elsewhere _outside_ the
>>  work tree.
>
> That's fair enough.  It's not enforced, or discourgaed in the
> documentation though.  Would a patch to mention that using --git-dir/GIT_DIR
> to change the name _inside_ the work tree is not supported be accepted?

i.e. this ...

 Documentation/git.txt |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/Documentation/git.txt b/Documentation/git.txt
index 3ed24d4..28cce7f 100644
--- a/Documentation/git.txt
+++ b/Documentation/git.txt
@@ -134,7 +134,8 @@ help ...'.
 
 --git-dir=<path>::
 	Set the path to the repository. This can also be controlled by
-	setting the GIT_DIR environment variable.
+	setting the GIT_DIR environment variable. Setting this to use a name
+	other than `.git` _inside_ the working tree is not supported.
 
 --work-tree=<path>::
 	Set the path to the working tree.  The value will not be
@@ -391,7 +392,8 @@ git so take care if using Cogito etc.
 'GIT_DIR'::
 	If the 'GIT_DIR' environment variable is set then it
 	specifies a path to use instead of the default `.git`
-	for the base of the repository.
+	for the base of the repository. Setting this to use a name
+	other than `.git` _inside_ the working tree is not supported.
 
 'GIT_WORK_TREE'::
 	Set the path to the working tree.  The value will not be
-- 
1.5.4.4

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux