<feed xmlns='http://www.w3.org/2005/Atom'>
<title>tools/git-repo.git/docs/repoconfig.md, branch v2.72</title>
<subtitle>Mirror of gerrit.googlesource.com/git-repo</subtitle>
<id>https://git.enea.com/cgit/tools/git-repo.git/atom?h=v2.72</id>
<link rel='self' href='https://git.enea.com/cgit/tools/git-repo.git/atom?h=v2.72'/>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/tools/git-repo.git/'/>
<updated>2026-10-22T15:34:46+00:00</updated>
<entry>
<title>config: add subcommand to manage ~/.repoconfig/config</title>
<updated>2026-10-22T15:34:46+00:00</updated>
<author>
<name>Insaf Latypov</name>
<email>saferif@google.com</email>
</author>
<published>2026-10-20T16:15:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/tools/git-repo.git/commit/?id=9991aa6177d34ee94bf0ae046cfc15dc5a08c328'/>
<id>urn:sha1:9991aa6177d34ee94bf0ae046cfc15dc5a08c328</id>
<content type='text'>
Per-user settings such as sync.smartsync live in ~/.repoconfig/config,
but reading or changing them required knowing the file location and
running `git config --file ~/.repoconfig/config ...`.

Add `repo config` as a thin wrapper around RepoConfig.ForUser(),
following the subcommand style of modern `git config`:
* `repo config get &lt;name&gt;` prints the value(s), exiting 1 if unset.
* `repo config set &lt;name&gt; &lt;value&gt;` sets it.
* `repo config unset &lt;name&gt;` removes it; a missing key is a no-op.
* `repo config list` shows all settings.

Values are stored as strings; `--type=bool|int` validates and
canonicalizes them on set and get, like `git config --type`.  `-z` makes
get and list NUL-terminated for scripting.  Setting names are validated
by `git config` itself when writing.

Factor the value parsing out of GitConfig.GetBoolean()/GetInt() into
ParseBoolean()/ParseInt() so the command and the readers agree, and
accept on/off/1/0 as booleans like git does.

Only the per-user file is handled; per-checkout settings in
.repo/manifests.git/config are out of scope.  Like other subcommands, it
runs from inside a repo checkout.

Update docs/repoconfig.md to use the new command in its examples and
add zsh completion and the man page.

Bug: 569927750
Test: ./run_tests
Change-Id: I940d0318549fe9d79f6f9173139f0b96a706f1bf
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/645727
Reviewed-by: Mike Frysinger &lt;vapier@google.com&gt;
Tested-by: Insaf Latypov &lt;saferif@google.com&gt;
Commit-Queue: Insaf Latypov &lt;saferif@google.com&gt;
</content>
</entry>
<entry>
<title>sync: Provide a CLI command to opt in/out of smartsync for a user.</title>
<updated>2026-10-19T19:20:06+00:00</updated>
<author>
<name>Insaf Latypov</name>
<email>saferif@google.com</email>
</author>
<published>2026-10-13T15:50:11+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/tools/git-repo.git/commit/?id=46e9866ca0f161604bd45a0c3b7c7887c9415dcb'/>
<id>urn:sha1:46e9866ca0f161604bd45a0c3b7c7887c9415dcb</id>
<content type='text'>
Add a boolean `sync.smartsync` setting in the per-user repo config
(~/.repoconfig/config):
* true: smart sync by default, as if -s were passed.
* false: never smart sync by default, even if the manifest enables it.
* unset: follow the manifest default, as before.

Add docs/repoconfig.md as the user facing documentation for
~/.repoconfig/config and its settings, and point smart-sync.md and the
`repo sync` help at it.

Bug: 569927750
Test: ./run_tests
Change-Id: Ideb4119fcb5e90f8bb35c493d9e4f8bec7878b77
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/643264
Reviewed-by: Gavin Mak &lt;gavinmak@google.com&gt;
Commit-Queue: Insaf Latypov &lt;saferif@google.com&gt;
Tested-by: Insaf Latypov &lt;saferif@google.com&gt;
</content>
</entry>
</feed>
