diff options
Diffstat (limited to 'packages/meshbay-node/src/meshbay_node/daemon.py')
| -rw-r--r-- | packages/meshbay-node/src/meshbay_node/daemon.py | 18 |
1 files changed, 5 insertions, 13 deletions
diff --git a/packages/meshbay-node/src/meshbay_node/daemon.py b/packages/meshbay-node/src/meshbay_node/daemon.py index a9376e7..74fff4c 100644 --- a/packages/meshbay-node/src/meshbay_node/daemon.py +++ b/packages/meshbay-node/src/meshbay_node/daemon.py @@ -1783,9 +1783,6 @@ def main() -> None: help="hub username, for init") parser.add_argument("--dir", default=None, help="shared directory, for group add") - parser.add_argument("--upload-dir", default=None, - help="deprecated: a second read-write root, for group " - "add. Use `root add <path> --writable` instead") parser.add_argument("--yes", action="store_true", help="skip the confirmation for destructive commands") parser.add_argument("--config", type=Path, default=None, @@ -2571,11 +2568,13 @@ def main() -> None: print("usage: meshbay-node group list|add|remove <name>") sys.exit(1) if not args.target or not args.dir: - print("usage: meshbay-node group add <name> --dir <path> [--upload-dir <path>]") + print("usage: meshbay-node group add <name> --dir <path> " + "[--no-writable]") print() print("The group must already exist on the hub and be yours. This") - print("only tells the node to host it, and picks the directory.") - print("--upload-dir sets a separate directory for uploaded files.") + print("only tells the node to host it, and picks its first") + print("directory, which accepts uploads unless --no-writable.") + print("Add more with: meshbay-node root add <path> [--writable]") sys.exit(1) cfg = load_config(args.config or DEFAULT_CONFIG_PATH) @@ -2586,17 +2585,10 @@ def main() -> None: writable = args.writable is not False body = {"name": args.target, "shared_dir": args.dir, "writable": writable} - if args.upload_dir: - print("WARNING: --upload-dir is deprecated. The shared directory is " - "read-write by default; use 'meshbay-node root add " - "<path> --writable' for a second one.") - body["upload_dir"] = args.upload_dir out = _daemon_api(cfg, "/api/groups/attach", method="POST", body=body) print(f"{out['name']} ({out['group_id'][:8]}) added to {out['config']}") print(f" shared_dir {out['shared_dir']}" f" ({'read-write' if writable else 'read-only'})") - if out.get("upload_dir"): - print(f" upload_dir {out['upload_dir']}") print() print("Tell the daemon to re-read its config, then give the group a key:") print(" meshbay-node reload") |