arg_parser.add_argument('--qr','-q',help='generate QR codes (otpauth://...)',action='store_true')
arg_parser.add_argument('--saveqr','-s',help='save QR code(s) as images to the "qr" subfolder',action='store_true')
arg_parser.add_argument('--printqr','-p',help='print QR code(s) as text to the terminal',action='store_true')
arg_parser.add_argument('infile',help='file or - for stdin (default: -) with "otpauth-migration://..." URLs separated by newlines, lines starting with # are ignored')
@ -62,11 +61,8 @@ verbose = args.verbose
saveqr=args.saveqr
printqr=args.printqr
ifargs.qr:
ifsaveqr orprintqr:
fromqrcodeimportQRCode
ifnot(saveqrorprintqr):
print("Error: If you specify to generate a QR code, you must specify how you want to receive it. Please specify -s or -p. Use -h or --help for more information")