summaryrefslogtreecommitdiff
path: root/tools/encrypt_secret.py
diff options
context:
space:
mode:
Diffstat (limited to 'tools/encrypt_secret.py')
-rwxr-xr-xtools/encrypt_secret.py9
1 files changed, 6 insertions, 3 deletions
diff --git a/tools/encrypt_secret.py b/tools/encrypt_secret.py
index e2ae048cd..32468fd2a 100755
--- a/tools/encrypt_secret.py
+++ b/tools/encrypt_secret.py
@@ -56,8 +56,11 @@ def main():
default=None,
help="The name of the Zuul tenant. This may be "
"required in a multi-tenant environment.")
- parser.add_argument('--strip', action='store_true', default=False,
- help="Strip whitespace from beginning/end of input.")
+ parser.add_argument('--strip', default=None,
+ help='Unused, kept for backward compatibility.')
+ parser.add_argument('--no-strip', action='store_true', default=False,
+ help="Do not strip whitespace from beginning or "
+ "end of input.")
parser.add_argument('--infile',
default=None,
help="A filename whose contents will be encrypted. "
@@ -119,7 +122,7 @@ def main():
plaintext = sys.stdin.read()
plaintext = plaintext.encode("utf-8")
- if args.strip:
+ if not args.no_strip:
plaintext = plaintext.strip()
pubkey_file = tempfile.NamedTemporaryFile(delete=False)