Summary: | git-2.eclass: ${PN}_LIVE_REPO makes git-2 use wrong storedir (egit-src/.git) | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | SpanKY <vapier> |
Component: | Eclasses | Assignee: | Donnie Berkholz (RETIRED) <dberkholz> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | mgorny |
Priority: | Normal | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Attachments: | When constructing storedir, strip trailing '/.git' directory. |
Description
SpanKY
![]() Ok, I see where the problem is. git-2_init_variables() updates EGIT_REPO_URI while git-2_prepare_storedir() would rather prefer seeing the original one. Although the best solution seems to mix the two functions a little, that wouldn't cover all the cases (especially when EGIT_REPO_URI is unset in the ebuild). As for the first step, I'd suggest you not to add '.git' to URIs. git should be able to do a neat clone from workdir as well. I'll also add stripping of trailing '.git' from EGIT_REPO_URI when constructing EGIT_DIR. The remaining question is: should git-2 always construct the storedir from current repo URI or the original one? What if there is no original URI? Created attachment 296745 [details, diff]
When constructing storedir, strip trailing '/.git' directory.
Fixes:
if i have ${PN}_LIVE_REPO set, i don't expect git-2.eclass to hit the network at all. further, i don't even really like git creating a full copy on disk. it should be re-using the git objects that live in my ${PN}_LIVE_REPO. Committed. |