<feed xmlns='http://www.w3.org/2005/Atom'>
<title>tools/git-repo.git/project.py, branch v1.13.11</title>
<subtitle>Mirror of gerrit.googlesource.com/git-repo</subtitle>
<id>https://git.enea.com/cgit/tools/git-repo.git/atom?h=v1.13.11</id>
<link rel='self' href='https://git.enea.com/cgit/tools/git-repo.git/atom?h=v1.13.11'/>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/tools/git-repo.git/'/>
<updated>2020-02-12T02:03:35+00:00</updated>
<entry>
<title>Revert "Save cookies back to jar when fetching clone.bundle"</title>
<updated>2020-02-12T02:03:35+00:00</updated>
<author>
<name>Mike Frysinger</name>
<email>vapier@google.com</email>
</author>
<published>2020-02-09T21:20:06+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/tools/git-repo.git/commit/?id=d92076d930af11bb9a3025a6b2f12ca139c0436f'/>
<id>urn:sha1:d92076d930af11bb9a3025a6b2f12ca139c0436f</id>
<content type='text'>
This reverts commit 4abf8e6ef81e78469148b156ae2d2da70ace627a.

The curl process for updating the cookie file is not atomic.  When
fetching many bundles in parallel, we can sometimes corrupt the file
causing it to be cleared.  Since users should manage gitcookies on
their own, leave it read-only.

Bug: https://crbug.com/gerrit/12300
Change-Id: Id472c99b197bc4cf8533c649f8881509f38643c1
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/254092
Reviewed-by: David Pursehouse &lt;dpursehouse@collab.net&gt;
Tested-by: Mike Frysinger &lt;vapier@google.com&gt;
(cherry picked from commit dc1d0e0c7fffa5109048ac52a67aa97bb362ae3a)
</content>
</entry>
<entry>
<title>project: fix bytes/str encoding when updating git submodules</title>
<updated>2020-02-11T19:46:13+00:00</updated>
<author>
<name>Mike Frysinger</name>
<email>vapier@google.com</email>
</author>
<published>2020-02-11T08:35:24+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/tools/git-repo.git/commit/?id=45d1c372a79fe35e1deb4956708432bc9ae80ea0'/>
<id>urn:sha1:45d1c372a79fe35e1deb4956708432bc9ae80ea0</id>
<content type='text'>
Since tempfile.mkstemp() returns a file handle in binary mode,
make sure we turn our strings into bytes before writing.

Bug: https://crbug.com/gerrit/12043
Change-Id: I3e84d595e84b8bc12a1fbc7fd0bb3ea0ba2832b0
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/254393
Reviewed-by: Michael Mortensen &lt;mmortensen@google.com&gt;
Reviewed-by: Mike Frysinger &lt;vapier@google.com&gt;
Tested-by: Mike Frysinger &lt;vapier@google.com&gt;
(cherry picked from commit 163d42eb43ba79677aae22fa859896010badba9b)
</content>
</entry>
<entry>
<title>remove spurious +x bits</title>
<updated>2020-02-11T04:31:03+00:00</updated>
<author>
<name>Mike Frysinger</name>
<email>vapier@google.com</email>
</author>
<published>2020-02-09T09:35:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/tools/git-repo.git/commit/?id=ef412624e953db6afdf402b18b004c0beabc5917'/>
<id>urn:sha1:ef412624e953db6afdf402b18b004c0beabc5917</id>
<content type='text'>
These files are not directly executable, so drop the +x bits.

Change-Id: Iaf19a03a497686cc21103e7ddf08073173440dd1
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/254076
Tested-by: Mike Frysinger &lt;vapier@google.com&gt;
Reviewed-by: David Pursehouse &lt;dpursehouse@collab.net&gt;
(cherry picked from commit e7c91889a6ff23931d3fbc25481b276e50ed8229)
</content>
</entry>
<entry>
<title>Do not try to fetch default revision for mirrors always</title>
<updated>2020-02-06T14:19:35+00:00</updated>
<author>
<name>Chirayu Desai</name>
<email>chirayudesai1@gmail.com</email>
</author>
<published>2020-02-04T12:20:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/tools/git-repo.git/commit/?id=ab15e42fa4403a0354c936d8740f864300b00929'/>
<id>urn:sha1:ab15e42fa4403a0354c936d8740f864300b00929</id>
<content type='text'>
* Mirrors may contain multiple projects, some of which may not
  always contain the default revision.
* Only fetch the default revision explicitly if
  '--current-branch' is set.
* Fixes breakage casued by
  commit 6856f98467aa5c98085cdee02587dbab984cebb1
  "Fix repo mirror with --current-branch"

Bug: https://crbug.com/gerrit/12274
Change-Id: Iaafabe2992f76f3644b841f24245d3e19c9515a9
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/253093
Reviewed-by: Kuang-che Wu &lt;kcwu@chromium.org&gt;
Reviewed-by: Mike Frysinger &lt;vapier@google.com&gt;
Tested-by: Chirayu Desai &lt;chirayudesai1@gmail.com&gt;
(cherry picked from commit f7b64e3350a622ee87e1927cdbc8d854a5696d85)
</content>
</entry>
<entry>
<title>Fix docstring of project.Project.PrintWorkTreeStatus()</title>
<updated>2020-01-25T13:29:56+00:00</updated>
<author>
<name>Rostislav Krasny</name>
<email>rostigm@gmail.com</email>
</author>
<published>2020-01-25T12:49:14+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/tools/git-repo.git/commit/?id=0bcc2d28d4b6a1dedcc01a7f48bc7bc7056d31ea'/>
<id>urn:sha1:0bcc2d28d4b6a1dedcc01a7f48bc7bc7056d31ea</id>
<content type='text'>
Change-Id: I1a9139d2ea3b3331a6f3ad3cae9e0ac37074d716
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/251837
Reviewed-by: Mike Frysinger &lt;vapier@google.com&gt;
Tested-by: Rostislav Krasny &lt;rostigm@gmail.com&gt;
</content>
</entry>
<entry>
<title>Fix repo mirror with --current-branch</title>
<updated>2019-11-25T20:12:34+00:00</updated>
<author>
<name>Kuang-che Wu</name>
<email>kcwu@chromium.org</email>
</author>
<published>2019-11-25T04:37:55+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/tools/git-repo.git/commit/?id=6856f98467aa5c98085cdee02587dbab984cebb1'/>
<id>urn:sha1:6856f98467aa5c98085cdee02587dbab984cebb1</id>
<content type='text'>
Before a2cd6aeae8, "repo mirror with --current-branch" fetches git data
using command
    git fetch --progress --update-head-ok cros --tags
No refspec is specified, thus it fetches default refspec, which is +refs/heads/*:refs/heads/*

After a2cd6aeae8, the fetch command became
     git fetch --progress --update-head-ok cros --tags +refs/tags/*:refs/tags/*
It did not only add tags refspec, but also suppressed the fetching of default refspec.

In other words, repo mirrors doesn't work if current_branch_only=True.
This CL explicitly adds the default refspec to command line if none is
specified.

Bug: https://crbug.com/gerrit/11990
Change-Id: Iadcf7b9aa50f53c47132cfe6c53b3fb2076ebca2
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/246632
Reviewed-by: David Pursehouse &lt;dpursehouse@collab.net&gt;
Reviewed-by: Mike Frysinger &lt;vapier@google.com&gt;
Tested-by: Kuang-che Wu &lt;kcwu@chromium.org&gt;
</content>
</entry>
<entry>
<title>prune: handle branches that track missing branches</title>
<updated>2019-11-16T19:55:02+00:00</updated>
<author>
<name>Mike Frysinger</name>
<email>vapier@google.com</email>
</author>
<published>2019-09-11T22:43:17+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/tools/git-repo.git/commit/?id=6da17751ca4e3b90834ca763f448ddc39b32651b'/>
<id>urn:sha1:6da17751ca4e3b90834ca763f448ddc39b32651b</id>
<content type='text'>
Series of steps:
* Create a local "b1" branch with `repo start b1` that tracks a remote
  branch (totally fine)
* Manually create a local "b2" branch with `git branch --track b1 b2`
  that tracks the local "b1" (uh-oh...)
* Delete the local "b1" branch manually or via `repo prune` (....)
* Try to process the "b2" branch with `repo prune`

Since b2 tracks a branch that no longer exists, everything blows up
at this point as we try to probe the non-existent ref.  Instead, we
should flag this as unknown and leave it up to the user to resolve.

This probably could come up if a local branch was tracking a remote
branch that was deleted from the server, and users ran something like
`repo sync --prune` which cleaned up the remote refs.

Bug: https://crbug.com/gerrit/11485
Change-Id: I6b6b6041943944b8efa6e2ad0b8b10f13a75a5c2
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/236793
Reviewed-by: David Pursehouse &lt;dpursehouse@collab.net&gt;
Reviewed-by: Kirtika Ruchandani &lt;kirtika@google.com&gt;
Reviewed-by: Mike Frysinger &lt;vapier@google.com&gt;
Tested-by: Mike Frysinger &lt;vapier@google.com&gt;
</content>
</entry>
<entry>
<title>sync: try to fast forward merge branches before checking published state</title>
<updated>2019-11-13T20:29:33+00:00</updated>
<author>
<name>Mike Frysinger</name>
<email>vapier@google.com</email>
</author>
<published>2019-09-23T21:42:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/tools/git-repo.git/commit/?id=2ba5a1e96347e735b12998c057a6c1eed79712e9'/>
<id>urn:sha1:2ba5a1e96347e735b12998c057a6c1eed79712e9</id>
<content type='text'>
If the local branch changed state since its last upload, the data
cached in .git/config related to the last uploaded CL might not be
that relevant.  If we're able to fast forward merge to the latest
tree state, then let's do that.  This would be akin to checking
out a detached head before syncing where we already switch state.

If we aren't able to fast forward merge, then it's not a big deal
as we'll continue on to the existing branch checking logic.

This would be easy to reproduce by doing something like:
  $ repo start foo .
  $ git revert HEAD
  $ repo upload --cbr .
  $ git reset --hard HEAD^
  &lt;CL is merged&gt;
  $ repo sync .
  &lt;we can fast forward&gt;

Change-Id: I7d62f3d1ba5314a349d85b4dbb0ec8352eca18bb
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/238552
Tested-by: Mike Frysinger &lt;vapier@google.com&gt;
Reviewed-by: Michael Mortensen &lt;mmortensen@google.com&gt;
Reviewed-by: Mike Frysinger &lt;vapier@google.com&gt;
</content>
</entry>
<entry>
<title>sync: add sanity check for local checkouts missing network</title>
<updated>2019-11-12T23:14:28+00:00</updated>
<author>
<name>Mike Frysinger</name>
<email>vapier@google.com</email>
</author>
<published>2019-11-11T10:10:03+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/tools/git-repo.git/commit/?id=b610b850ac2d791e193383dd77501565fca60aa4'/>
<id>urn:sha1:b610b850ac2d791e193383dd77501565fca60aa4</id>
<content type='text'>
If you run `repo sync -l foo` without first `repo sync -n foo`,
repo sets up an invalid gitdir tree that gets wedged and requires
manual recovery.  Add a sanity check to abort cleanly first.

Change-Id: Iad865ea860a3f1fd2f39ce683fe66bd4380745a5
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/244732
Reviewed-by: David Pursehouse &lt;dpursehouse@collab.net&gt;
Tested-by: Mike Frysinger &lt;vapier@google.com&gt;
</content>
</entry>
<entry>
<title>use open context managers in more places</title>
<updated>2019-11-12T03:44:39+00:00</updated>
<author>
<name>Mike Frysinger</name>
<email>vapier@google.com</email>
</author>
<published>2019-11-11T10:40:22+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/tools/git-repo.git/commit/?id=3164d40e2247d42537aef8e80fa7e048e14bec9f'/>
<id>urn:sha1:3164d40e2247d42537aef8e80fa7e048e14bec9f</id>
<content type='text'>
Use open() as a context manager to simplify the close logic and make
the code easier to read &amp; understand.  This is also more Pythonic.

Change-Id: I579d03cca86f99b2c6c6a1f557f6e5704e2515a7
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/244734
Reviewed-by: David Pursehouse &lt;dpursehouse@collab.net&gt;
Tested-by: Mike Frysinger &lt;vapier@google.com&gt;
</content>
</entry>
</feed>
