diff options
Diffstat (limited to 'bitbake')
-rw-r--r-- | bitbake/lib/bb/fetch2/git.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/bitbake/lib/bb/fetch2/git.py b/bitbake/lib/bb/fetch2/git.py index f3bc793a6a..7954f66ac5 100644 --- a/bitbake/lib/bb/fetch2/git.py +++ b/bitbake/lib/bb/fetch2/git.py | |||
@@ -170,7 +170,7 @@ class Git(FetchMethod): | |||
170 | 170 | ||
171 | # If the repo still doesn't exist, fallback to cloning it | 171 | # If the repo still doesn't exist, fallback to cloning it |
172 | if not os.path.exists(ud.clonedir): | 172 | if not os.path.exists(ud.clonedir): |
173 | clone_cmd = "%s clone --bare %s://%s%s%s %s" % \ | 173 | clone_cmd = "%s clone --bare --mirror %s://%s%s%s %s" % \ |
174 | (ud.basecmd, ud.proto, username, ud.host, ud.path, ud.clonedir) | 174 | (ud.basecmd, ud.proto, username, ud.host, ud.path, ud.clonedir) |
175 | bb.fetch2.check_network_access(d, clone_cmd) | 175 | bb.fetch2.check_network_access(d, clone_cmd) |
176 | runfetchcmd(clone_cmd, d) | 176 | runfetchcmd(clone_cmd, d) |
@@ -188,7 +188,7 @@ class Git(FetchMethod): | |||
188 | except bb.fetch2.FetchError: | 188 | except bb.fetch2.FetchError: |
189 | logger.debug(1, "No Origin") | 189 | logger.debug(1, "No Origin") |
190 | 190 | ||
191 | runfetchcmd("%s remote add origin %s://%s%s%s" % (ud.basecmd, ud.proto, username, ud.host, ud.path), d) | 191 | runfetchcmd("%s remote add --mirror origin %s://%s%s%s" % (ud.basecmd, ud.proto, username, ud.host, ud.path), d) |
192 | fetch_cmd = "%s fetch --all -t" % ud.basecmd | 192 | fetch_cmd = "%s fetch --all -t" % ud.basecmd |
193 | bb.fetch2.check_network_access(d, fetch_cmd, ud.url) | 193 | bb.fetch2.check_network_access(d, fetch_cmd, ud.url) |
194 | runfetchcmd(fetch_cmd, d) | 194 | runfetchcmd(fetch_cmd, d) |