aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWynn Wolf Arbor <wolf@oriole.systems>2020-07-02 17:50:17 +0200
committerZac Medico <zmedico@gentoo.org>2020-07-02 14:37:02 -0700
commit141ef203661248a2c29945f8c6770ce0c242eaf0 (patch)
tree00ce690120fd09f00318fd1d847c55bd60179e47 /lib/portage/sync/modules/git/git.py
parentecompress: optimize docompress -x precompressed comparison (diff)
downloadportage-141ef203661248a2c29945f8c6770ce0c242eaf0.tar.gz
portage-141ef203661248a2c29945f8c6770ce0c242eaf0.tar.bz2
portage-141ef203661248a2c29945f8c6770ce0c242eaf0.zip
repos.conf: Use consistent list of values for boolean options
Valid values for boolean options in repos.conf are currently not managed in a consistent manner. Some options only support 'true' and 'false', whilst others additionally support 'yes' and 'no'. Using the latter forms on options that do not support them will lead to unexpected behaviour. For example, an option checking for 'true' will be disabled when 'yes' is used. This is counter-intuitive and adds additional burden: the user has to look up in the manual which form is accepted by which option. Have all boolean options consistently accept 'yes', 'no', 'true', and 'false' and make sure to document this in the portage(5) manual. Additionally, document the default value for each. Signed-off-by: Wynn Wolf Arbor <wolf@oriole.systems> Signed-off-by: Zac Medico <zmedico@gentoo.org>
Diffstat (limited to 'lib/portage/sync/modules/git/git.py')
-rw-r--r--lib/portage/sync/modules/git/git.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/portage/sync/modules/git/git.py b/lib/portage/sync/modules/git/git.py
index 7df4b6d61..ed8c1979f 100644
--- a/lib/portage/sync/modules/git/git.py
+++ b/lib/portage/sync/modules/git/git.py
@@ -1,4 +1,4 @@
-# Copyright 2005-2018 Gentoo Foundation
+# Copyright 2005-2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
import io
@@ -204,7 +204,7 @@ class GitSync(NewBase):
def verify_head(self, revision='-1'):
if (self.repo.module_specific_options.get(
- 'sync-git-verify-commit-signature', 'false') != 'true'):
+ 'sync-git-verify-commit-signature', 'false').lower() not in ('true', 'yes')):
return True
if self.repo.sync_openpgp_key_path is not None: