@wspc/cli 0.0.21 → 0.0.23

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  Official TypeScript SDK and CLI for [wspc.ai](https://wspc.ai).
4
4
 
5
- > Status: **v0 walking skeleton.** Covers the todo domain only.
5
+ > Status: **v0 walking skeleton.** Covers todo commands plus the first manual Drive sync slice.
6
6
 
7
7
  ## Install
8
8
 
@@ -39,10 +39,30 @@ scopes todos per project. Run `wspc todo project ls` to discover ids.
39
39
  | `wspc todo project {add, ls}` | Project scope. |
40
40
  | `wspc todo type ls` | List todo types. |
41
41
  | `wspc todo rule ls` | List recurrence rules. |
42
+ | `wspc drive bind --library <id> [path]` | Bind an existing Drive library to a local folder. |
43
+ | `wspc drive sync once [path]` | Run one manual whole-file Drive sync pass. |
42
44
  | `wspc config` | Inspect / clear local config. |
43
45
 
44
46
  Pass `--help` to any subcommand for flags, aliases, and examples.
45
47
 
48
+ ## Drive sync
49
+
50
+ Bind a local folder to an existing Drive library, then run sync explicitly:
51
+
52
+ ```bash
53
+ wspc drive bind --library lib_xxx ./notes
54
+ wspc drive sync once ./notes
55
+ ```
56
+
57
+ `bind` does not create a server library. It verifies the existing library, writes
58
+ `.wspc-drive/state.json`, and waits for an explicit `sync once`.
59
+
60
+ `sync once` is the v1 safe manual sync path: it performs a full folder scan,
61
+ compares local files with the remote manifest, uploads/downloads whole files,
62
+ uses optimistic remote versions for updates/deletes, and records conflicts in
63
+ local state instead of auto-merging them. It does not run a watcher, preserve
64
+ empty directories, detect renames, or create remote libraries.
65
+
46
66
  ### Running a command as a specific account
47
67
 
48
68
  You can run any single command as a particular account without switching the active one:
package/dist/cli.d.ts CHANGED
@@ -1,6 +1,10 @@
1
1
  #!/usr/bin/env node
2
+ import { Command } from 'commander';
3
+
4
+ declare function mountDriveCommands(program: Command): void;
5
+ declare function isCliEntrypoint(argv?: string[], metaUrl?: string): boolean;
2
6
  declare function dispatch(argv: string[], { allowRetry }?: {
3
7
  allowRetry?: boolean;
4
8
  }): Promise<void>;
5
9
 
6
- export { dispatch };
10
+ export { dispatch, isCliEntrypoint, mountDriveCommands };