fix(auth,ui): add auth webview cli entrypoint and bulk action progress bar
This commit is contained in:
@@ -74,5 +74,21 @@ def main_auth(auth_url, output_path):
|
||||
webview.start(private_mode=False, storage_path=storage_path)
|
||||
|
||||
|
||||
def main():
|
||||
# Supports both: `python auth_webview.py <auth_url> <output_path>`
|
||||
# and: `python auth_webview.py --auth <auth_url> <output_path>`
|
||||
args = sys.argv[1:]
|
||||
if len(args) == 3 and args[0] == "--auth":
|
||||
auth_url, output_path = args[1], args[2]
|
||||
elif len(args) == 2:
|
||||
auth_url, output_path = args[0], args[1]
|
||||
else:
|
||||
print("Usage: auth_webview.py [--auth] <auth_url> <output_path>")
|
||||
return 1
|
||||
|
||||
main_auth(auth_url, output_path)
|
||||
return 0
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
||||
sys.exit(main())
|
||||
|
||||
Reference in New Issue
Block a user