Verified Commit 570603e0 authored by anarcat's avatar anarcat
Browse files

do not echo password when prompting

parent 3f82c44b
......@@ -35,6 +35,7 @@
import argparse
from getpass import getpass
import logging
import os
import re
......@@ -103,7 +104,7 @@ class BatchArgParser(argparse.ArgumentParser):
def parse_args(self, *args, **kwargs):
args = super().parse_args(*args, **kwargs)
if args.password is None:
args.password = input("Password:")
args.password = getpass("Password:")
for attr in ('location', 'username', 'password'):
if not getattr(args, attr):
self.error("no %s provided, provide one with --%s or WEBDAV_%s environment" % (attr, attr, attr.upper()))
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment