]> glassweightruler.freedombox.rocks Git - waydroid.git/blobdiff - tools/__init__.py
logging: Add date to the logfile format
[waydroid.git] / tools / __init__.py
index 9a4701b0bc961a4fb2ba7cf89423b3e5f616f68b..e493d53249565d3e422d03a5b6ffc3cdbce1895d 100644 (file)
@@ -24,7 +24,6 @@ def main():
     # Wrap everything to display nice error messages
     args = None
     try:
-        os.umask(0o000)
         # Parse arguments, set up logging
         args = helpers.arguments()
         args.cache = {}
@@ -111,11 +110,9 @@ def main():
                     "Run waydroid {} -h for usage information.".format(args.action))
         elif args.action == "prop":
             if args.subaction == "get":
-                ret = helpers.props.get(args, args.key)
-                if ret:
-                    print(ret)
+                actions.prop.get(args)
             elif args.subaction == "set":
-                helpers.props.set(args, args.key, args.value)
+                actions.prop.set(args)
             else:
                 logging.info(
                     "Run waydroid {} -h for usage information.".format(args.action))
@@ -133,6 +130,13 @@ def main():
                 actions.app_manager.showFullUI(args)
         elif args.action == "status":
             actions.status.print_status(args)
+        elif args.action == "adb":
+            if args.subaction == "connect":
+                helpers.net.adb_connect(args)
+            elif args.subaction == "disconnect":
+                helpers.net.adb_disconnect(args)
+            else:
+                logging.info("Run waydroid {} -h for usage information.".format(args.action))
         elif args.action == "log":
             if args.clear_log:
                 helpers.run.user(args, ["truncate", "-s", "0", args.log])