From: Junio C Hamano <gitster@pobox•com>
To: Stefan Beller <sbeller@google•com>
Cc: Yaroslav Halchenko <yoh@onerussian•com>,
Git Gurus hangout <git@vger•kernel.org>,
Benjamin Poldrack <benjaminpoldrack@gmail•com>,
Joey Hess <id@joeyh•name>, Jens Lehmann <Jens.Lehmann@web•de>
Subject: Re: problems serving non-bare repos with submodules over http
Date: Wed, 20 Apr 2016 12:51:23 -0700 [thread overview]
Message-ID: <xmqqh9ewukhw.fsf@gitster.mtv.corp.google.com> (raw)
In-Reply-To: <CAGZ79kYS-F1yKpNP7jmhTiZT1R_pucUBBTCbmHKZz6Xd6dy8EA@mail.gmail.com> (Stefan Beller's message of "Wed, 20 Apr 2016 09:14:08 -0700")
Stefan Beller <sbeller@google•com> writes:
>> 1. After cloning
>>
>> git clone http://localhost:8080/.git
>>
>> I cannot 'submodule update' the sub1 in the clone since its url after
>> 'submodule init' would be http://localhost:8080/.git/sub1 . If I manually fix
>> it up -- it seems to proceed normally since in original repository I have
>> sub1/.git/ directory and not the "gitlink" for that submodule.
>
> So the expected URL would be http://localhost:8080/sub1/.git ?
>
> I thought you could leave out the .git prefix, i.e. you can type
>
> git clone http://localhost:8080
>
> and Git will recognize the missing .git and try that as well. The relative URL
> would then be constructed as http://localhost:8080/sub1, which will use the
> same mechanism to find the missing .git ending.
I may be missing the subtleties, but if you are serving others from
a non-bare repository with submodules, I do not think you would want
to expose the in-tree version of the submodule in the first place.
These $submodule/.git files point via "gitdir:" to their real
repository location, don't they? And I would think that they are
what you would want to expose to the outside world. Your in-tree
submodules may come and go as you checkout different branches in
your working tree, but these copies at their real locations will
stay.
next prev parent reply other threads:[~2016-04-20 19:51 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-04-20 15:22 problems serving non-bare repos with submodules over http Yaroslav Halchenko
2016-04-20 16:14 ` Stefan Beller
2016-04-20 19:45 ` Yaroslav Halchenko
2016-04-20 19:51 ` Junio C Hamano [this message]
2016-04-20 21:05 ` Stefan Beller
2016-04-20 21:27 ` Junio C Hamano
2016-04-20 23:05 ` Stefan Beller
2016-04-21 3:14 ` Yaroslav Halchenko
2016-04-21 17:11 ` Stefan Beller
2016-04-21 17:45 ` Junio C Hamano
2016-04-21 17:48 ` Stefan Beller
2016-04-21 22:42 ` Jacob Keller
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=xmqqh9ewukhw.fsf@gitster.mtv.corp.google.com \
--to=gitster@pobox$(echo .)com \
--cc=Jens.Lehmann@web$(echo .)de \
--cc=benjaminpoldrack@gmail$(echo .)com \
--cc=git@vger$(echo .)kernel.org \
--cc=id@joeyh$(echo .)name \
--cc=sbeller@google$(echo .)com \
--cc=yoh@onerussian$(echo .)com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox