summaryrefslogtreecommitdiffstats
path: root/main.py
diff options
context:
space:
mode:
authorMike Frysinger <vapier@google.com>2020-02-17 14:36:08 -0500
committerDavid Pursehouse <dpursehouse@collab.net>2020-02-19 00:24:43 +0000
commitc58ec4dba102d88fec67e833eb8421202eb4c1ea (patch)
treec8c84e03f9359ae9dd126854069d34207c298831 /main.py
parente1191b3adb22e0b406db87691b13ddab2c236267 (diff)
downloadgit-repo-c58ec4dba102d88fec67e833eb8421202eb4c1ea.tar.gz
avoid negative variables
Trying to use booleans with names like "no_xxx" are hard to follow due to the double negatives. Invert all of them so we only have positive meanings to follow. Change-Id: Ifd37d0368f97034d94aa2cf38db52c723ac0c6ed Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/255493 Tested-by: Mike Frysinger <vapier@google.com> Reviewed-by: David Pursehouse <dpursehouse@collab.net>
Diffstat (limited to 'main.py')
-rwxr-xr-xmain.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/main.py b/main.py
index ec031a4c..9846d24f 100755
--- a/main.py
+++ b/main.py
@@ -108,7 +108,7 @@ global_options.add_option('-p', '--paginate',
108 dest='pager', action='store_true', 108 dest='pager', action='store_true',
109 help='display command output in the pager') 109 help='display command output in the pager')
110global_options.add_option('--no-pager', 110global_options.add_option('--no-pager',
111 dest='no_pager', action='store_true', 111 dest='pager', action='store_false',
112 help='disable the pager') 112 help='disable the pager')
113global_options.add_option('--color', 113global_options.add_option('--color',
114 choices=('auto', 'always', 'never'), default=None, 114 choices=('auto', 'always', 'never'), default=None,
@@ -222,7 +222,7 @@ class _Repo(object):
222 file=sys.stderr) 222 file=sys.stderr)
223 return 1 223 return 1
224 224
225 if not gopts.no_pager and not isinstance(cmd, InteractiveCommand): 225 if gopts.pager and not isinstance(cmd, InteractiveCommand):
226 config = cmd.manifest.globalConfig 226 config = cmd.manifest.globalConfig
227 if gopts.pager: 227 if gopts.pager:
228 use_pager = True 228 use_pager = True