fix(cli): preserve notes during sync moves
Build and Push Docker Container / build-and-push (push) Successful in 1m52s

- Leave sync and watch notes empty by default instead of writing placeholder text.
- Preserve existing remote notes when moving or adopting files without --note.
- Detect tracked local moves by SHA-256 and update remote metadata safely.
- Skip files that vanish during watch scans instead of aborting the sync cycle.
- Bump NanoShare to 1.24.0 and the standalone CLI to 0.3.0.
This commit is contained in:
2026-07-27 21:40:30 +02:00
parent 993337be9f
commit 2b0215cd94
9 changed files with 95 additions and 15 deletions
+3 -2
View File
@@ -25,13 +25,14 @@ def upload(client, node: str, path: Path, remote_name: str, note: str, expires:
result = client.call(node, 'files.upload', params)
return result if isinstance(result, dict) else {'result': result}
def update_remote(client, node: str, file_id: str, file_name: str, file_path: str, note: str, expires: str) -> None:
def update_remote(client, node: str, file_id: str, file_name: str, file_path: str, note: str | None, expires: str) -> None:
params = {
'file_id': file_id,
'file_name': file_name,
'file_path': file_path,
'note': note,
}
if note is not None:
params['note'] = note
if expires:
params['expires'] = expires
client.call(node, 'files.update', params)