summaryrefslogtreecommitdiffstats
path: root/packages/meshbay-node/src/meshbay_node/daemon.py
diff options
context:
space:
mode:
authorChristophe Besson <cbesson@gmail.com>2026-08-19 16:36:29 +0200
committerChristophe Besson <cbesson@gmail.com>2026-08-19 16:36:29 +0200
commit90c3c6a01f46c9b29c5d92702d7383f32e8951d7 (patch)
tree779f5ee3557d5111e0a7f1fdc211a2845bc3bc69 /packages/meshbay-node/src/meshbay_node/daemon.py
parent9498ce0a34cc363e8cf9a42575c8fcf7dfe0fd1a (diff)
downloadmeshbay-90c3c6a01f46c9b29c5d92702d7383f32e8951d7.tar.gz
feat(ui): 11-point UI overhaul — tabs, transfers, settings, uploads
Hub/UI: - Icon-only group tabs (chat, files, settings) with per-group default tab - Transfer widget: filename becomes a clickable link to open completed downloads - Pulse animation on transfer icon (pale→dark green) while active - Download button feedback in FilePreview (spinner, auto-reset) - Group mute toggle persists across navigation - Login page autofocus, chat refocus after send - Theme toggle closes menu, status badge and duplicate connecting removed - Create-folder restricted to operators, download-path note removed - User preferences API (CRUD) with Alembic migration - Profile: email display/edit via PATCH /v1/users/me - Settings: "Defaults" section for default tab selector - All 10 locale files updated Node: - upload_dir in node.toml: separate filesystem path for uploads - Root.direct flag: uploads land at root path, no subdirectory - CLI --upload-dir flag on `group add` - Admin UI accepts upload_dir Client (Electron): - shell.openPath bridge for opening completed downloads - platform.js passes open callback from native save Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Diffstat (limited to 'packages/meshbay-node/src/meshbay_node/daemon.py')
-rw-r--r--packages/meshbay-node/src/meshbay_node/daemon.py19
1 files changed, 14 insertions, 5 deletions
diff --git a/packages/meshbay-node/src/meshbay_node/daemon.py b/packages/meshbay-node/src/meshbay_node/daemon.py
index 45aca7a..6d4f172 100644
--- a/packages/meshbay-node/src/meshbay_node/daemon.py
+++ b/packages/meshbay-node/src/meshbay_node/daemon.py
@@ -799,6 +799,8 @@ def main() -> None:
"denylist clear")
parser.add_argument("--dir", default=None,
help="shared directory, for group add")
+ parser.add_argument("--upload-dir", default=None,
+ help="separate upload directory, for group add")
parser.add_argument("--yes", action="store_true",
help="skip the confirmation for destructive commands")
parser.add_argument("--config", type=Path, default=None,
@@ -1147,7 +1149,9 @@ def main() -> None:
f"{g.get('peers', 0)} peer(s)")
print(f" {g['id']}")
for r in g.get("roots", []):
- flags = " (uploads)" if r.get("upload") else ""
+ flags = ""
+ if r.get("upload"):
+ flags = " (uploads, direct)" if r.get("direct") else " (uploads)"
live = "" if r.get("available", True) else " [UNAVAILABLE]"
print(f" root {r['name']}{flags}{live}")
if not g.get("has_gek"):
@@ -1156,20 +1160,25 @@ def main() -> None:
return
if args.subcommand != "add":
- print("usage: meshbay-node group list|add <name> --dir <path>")
+ print("usage: meshbay-node group list|add <name> --dir <path> [--upload-dir <path>]")
sys.exit(1)
if not args.target or not args.dir:
- print("usage: meshbay-node group add <name> --dir <path>")
+ print("usage: meshbay-node group add <name> --dir <path> [--upload-dir <path>]")
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.")
sys.exit(1)
cfg = load_config(args.config or DEFAULT_CONFIG_PATH)
- out = _daemon_api(cfg, "/api/groups/attach", method="POST",
- body={"name": args.target, "shared_dir": args.dir})
+ body = {"name": args.target, "shared_dir": args.dir}
+ if args.upload_dir:
+ 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']}")
+ 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")