dotshare-cli 3.0.0 → 3.0.1

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
@@ -12,7 +12,7 @@
12
12
  [![License: Apache 2.0](https://img.shields.io/badge/License-Apache_2.0-blue.svg)](https://github.com/kareem2099/DotShare/blob/master/LICENSE)
13
13
  [![GitHub Stars](https://img.shields.io/github/stars/kareem2099/DotShare?style=flat&logo=github)](https://github.com/kareem2099/DotShare)
14
14
 
15
- [Install](#-install) · [Features](#-features) · [Platforms](#-supported-platforms) · [Pricing](#-free-vs-dotsuite-plans) · [Setup guides](#-platform-setup-guides) · [FAQ](#-faq) · [Website](https://dotsuite.dev/en/product/dotshare)
15
+ [Install](#-install) · [MCP quick start](#quick-start-for-ai-agents) · [Publishing Library](docs/PUBLISHING_LIBRARY.md) · [Changelog](CHANGELOG.md) · [Website](https://dotsuite.dev/en/product/dotshare)
16
16
 
17
17
  </div>
18
18
 
@@ -31,11 +31,11 @@
31
31
  - **Saved previews and receipts** that record exactly which draft revision was published and where.
32
32
  - **Encrypted local records** with an OS-keyring master key and verified migration for existing libraries.
33
33
 
34
- 👉 [Full changelog](https://github.com/kareem2099/DotShare/blob/master/CHANGELOG.md)
34
+ [Download VS Code 3.6.0 (.vsix)](https://github.com/kareem2099/DotShare/releases/download/v3.6.0/dotshare-3.6.0.vsix) · [CLI and MCP on npm](https://www.npmjs.com/package/dotshare-cli) · [Release notes and tarball](https://github.com/kareem2099/DotShare/releases/tag/v3.6.0)
35
35
 
36
36
  ---
37
37
 
38
- ## 🤖 Publish through an AI agent
38
+ ## Quick start for AI agents
39
39
 
40
40
  DotShare now includes a local **MCP server** and an agent CLI. Connect Codex or another
41
41
  MCP client, then ask it to preview or publish posts, images and threads to named
@@ -43,17 +43,28 @@ accounts on LinkedIn, X, Bluesky, Mastodon, Telegram, Discord and Dev.to. Per-ac
43
43
  content, multiple accounts, durable retry protection and DotSuite cloud scheduling
44
44
  are available through structured tools.
45
45
 
46
- Install `dotshare-cli-3.0.0.tgz` from the [GitHub release](https://github.com/kareem2099/DotShare/releases/tag/v3.6.0)
47
- with `npm install -g ./dotshare-cli-3.0.0.tgz`, or build this checkout with `npm run compile`.
48
- Run `dotshare-agent setup` to connect Codex, then `dotshare-agent doctor` to verify
49
- the connection. Connect accounts with `dotshare-agent accounts add`.
50
- `dotshare-agent doctor --check-accounts` checks platform identities without publishing.
51
- From a source checkout, replace `dotshare-agent` with `node bin/dotshare-agent.js`.
46
+ Use Node.js 22.12+ and an unlocked OS credential store. Install the CLI and MCP
47
+ server from npm, then connect Codex and a publishing account.
52
48
 
53
- Existing users should run `dotshare-agent security protect` and restart
54
- all MCP clients/VS Code windows. Shared library records are encrypted with an
55
- OS-keyring master key; Linux requires Secret Service without automatic fallback.
56
- See [the local security model and recovery requirements](SECURITY.md).
49
+ ```sh
50
+ npm install -g dotshare-cli
51
+ dotshare-agent setup
52
+ dotshare-agent accounts add personal-mastodon --platform mastodon
53
+ dotshare-agent doctor --account personal-mastodon
54
+ ```
55
+
56
+ Enter the Mastodon instance and token in the terminal prompts. After setup, reconnect
57
+ or restart Codex. Try this prompt to save a draft and prepare a preview:
58
+
59
+ > Use DotShare to save a draft titled “My first DotShare post” for `personal-mastodon` with the text “Hello from DotShare!” and prepare a preview for me to review.
60
+
61
+ To review it in VS Code, install the extension and run **DotShare: Open Publishing Library**
62
+ from the Command Palette. Open the draft and review it before selecting **Publish this saved preview**.
63
+ The receipt includes the result for each account and the post URL when the platform returns one.
64
+
65
+ Upgrading an existing library? Stop active publications, run `dotshare-agent security protect`,
66
+ and restart all DotShare MCP clients and VS Code windows. Linux requires an unlocked Secret Service
67
+ session. See the [upgrade and recovery guide](SECURITY.md#upgrading-an-existing-library).
57
68
 
58
69
  Saved drafts have explicit **Draft → Preview → Published** states, with separate
59
70
  in-progress/uncertain results and publication URLs. Editing invalidates the preview;
@@ -92,6 +103,9 @@ composer drafts remain in their existing screen; no automatic migration occurs.
92
103
  code --install-extension freerave.dotshare
93
104
  ```
94
105
 
106
+ **From GitHub:** download the `v3.6.0` VSIX above and run `code --install-extension ./dotshare-3.6.0.vsix`.
107
+ For the shared Publishing Library, also complete the [MCP quick start](#quick-start-for-ai-agents).
108
+
95
109
  Also available on the [Visual Studio Marketplace](https://marketplace.visualstudio.com/items?itemName=freerave.dotshare) and [Open VSX](https://open-vsx.org/extension/freerave/dotshare) (VSCodium, Cursor, Windsurf and other compatible editors). Requires VS Code **1.90** or later.
96
110
 
97
111
  ### Quick start
@@ -176,7 +190,7 @@ See current plans on the [DotShare page on DotSuite](https://dotsuite.dev/en/pro
176
190
  <summary><b>🐘 Mastodon</b></summary>
177
191
 
178
192
  1. On your Mastodon server, open **Preferences → Development → New application** (for example `https://mastodon.social/settings/applications/new`).
179
- 2. Enter any name, keep the redirect URI as `urn:ietf:wg:oauth:2.0:oob`, and enable only **`write:statuses`** and **`write:media`**.
193
+ 2. Enter any name, keep the redirect URI as `urn:ietf:wg:oauth:2.0:oob`, and enable only **`write:statuses`**, **`write:media`** and **`profile`** (`profile` lets `dotshare-agent doctor` verify the account).
180
194
  3. Save, open the application, and copy **Your access token**.
181
195
  4. In DotShare's Mastodon card, enter your instance URL (such as `https://mastodon.social`) and the token.
182
196
 
@@ -227,18 +241,17 @@ Generate a key under [Dev.to Settings → Extensions](https://dev.to/settings/ex
227
241
  ## ⌨️ DotShare CLI
228
242
 
229
243
  Use named local accounts from your terminal or CI. Requires Node.js 22.12+ and
230
- an unlocked OS credential store. Build/install this checkout for the current agent
231
- and security features; older published npm packages do not contain them.
244
+ an unlocked OS credential store. Install the CLI with `npm install -g dotshare-cli`.
245
+ With an account already connected, save and preview a draft from the terminal:
232
246
 
233
247
  ```bash
234
- node bin/dotshare-agent.js security protect
235
- node bin/dotshare-agent.js accounts add personal-mastodon --platform mastodon
236
- node bin/dotshare-agent.js templates list
237
- node bin/dotshare-agent.js drafts create --input draft.json
238
- node bin/dotshare-agent.js drafts preview DRAFT_ID --revision 1
239
- node bin/dotshare-agent.js drafts publish DRAFT_ID --revision 1 --preview-id PREVIEW_ID --request-id release-1
248
+ printf '%s\n' '{"title":"My first draft","content":{"accountIds":["personal-mastodon"],"text":"Hello from DotShare!"}}' | dotshare-agent drafts create --input -
249
+ dotshare-agent drafts preview DRAFT_ID --revision 1
240
250
  ```
241
251
 
252
+ Replace `DRAFT_ID` with the ID from the create response. After reviewing the output,
253
+ see the [CLI draft commands](docs/AGENT_INTEGRATION.md) for publishing the saved revision.
254
+
242
255
  Credentials stay in the required OS keyring. Shared drafts, custom templates and
243
256
  journals are encrypted with a separate OS-keyring master key. The old `dotshare
244
257
  "message"` relay and legacy login are disabled; use the direct named-account tools.
@@ -10,14 +10,21 @@ The local MCP server uses stdio and does not require a separate model/API key.
10
10
  Requires Node.js 22.12+ and an unlocked OS credential store. On Linux, a working
11
11
  Secret Service/keyring session is required. There is no plaintext secret fallback.
12
12
 
13
- Download `dotshare-cli-3.0.0.tgz` from the [GitHub release](https://github.com/kareem2099/DotShare/releases/tag/v3.6.0).
13
+ Install the CLI and MCP server from npm. For an existing library, follow the [upgrade steps](#local-storage-protection) before resuming publication.
14
14
 
15
15
  ```sh
16
- npm install -g ./dotshare-cli-3.0.0.tgz
16
+ npm install -g dotshare-cli
17
17
  dotshare-agent setup
18
- dotshare-agent doctor
18
+ dotshare-agent accounts add personal-mastodon --platform mastodon --name "Personal Mastodon"
19
+ dotshare-agent doctor --account personal-mastodon
19
20
  ```
20
21
 
22
+ Restart or reconnect Codex after setup. In Codex, ask DotShare to list your local
23
+ accounts, save a draft for one of them and prepare its preview. To review that draft
24
+ in VS Code, follow the [Publishing Library guide](PUBLISHING_LIBRARY.md).
25
+
26
+ You can also download the tarball and install it with `npm install -g ./dotshare-cli-3.0.0.tgz`. [GitHub release](https://github.com/kareem2099/DotShare/releases/tag/v3.6.0)
27
+
21
28
  To build and configure from source instead:
22
29
 
23
30
  ```sh
@@ -30,9 +37,9 @@ node bin/dotshare-agent.js accounts add work-linkedin --platform linkedin --name
30
37
  node bin/dotshare-agent.js accounts list
31
38
  ```
32
39
 
33
- Account setup prompts hide typed credentials. Connect each account in your
34
- terminal; do not paste platform secrets into an agent conversation. Existing VS Code
35
- accounts are not automatically copied. Multiple accounts on one platform use
40
+ Account setup prompts hide typed credentials. Enter platform secrets in your
41
+ terminal prompts. Existing VS Code accounts are not automatically copied.
42
+ Multiple accounts on one platform use
36
43
  different IDs. To replace an account's credentials, run `accounts add` with its ID.
37
44
  `accounts remove <id>` removes the local account and deletes its credential from the OS keyring.
38
45
  It does not revoke the token on the platform. Expired/revoked platform tokens must
@@ -69,17 +76,24 @@ The master key is generated randomly and stored in the OS keyring only; a locked
69
76
  missing or mismatched key fails closed. Restore the original OS key and security.json
70
77
  instead of generating a replacement key for existing ciphertext.
71
78
 
72
- For an existing installation, stop active publications, then run:
79
+ To upgrade an existing installation, stop active publications and run these commands.
73
80
 
74
81
  ```sh
75
- node bin/dotshare-agent.js security status
76
- node bin/dotshare-agent.js security protect
82
+ npm install -g dotshare-cli
83
+ dotshare-agent security status
84
+ dotshare-agent security protect
77
85
  ```
78
86
 
87
+ For a source checkout, substitute `node bin/dotshare-agent.js` for `dotshare-agent`.
88
+ If you switched from a source checkout to the installed package, use
89
+ `dotshare-agent setup --dry-run --replace` to review the new launcher paths.
90
+ Then run `dotshare-agent setup --replace` to replace the existing DotShare entry.
91
+ Review the media roots and include `--media-root` for any directory you want to allow.
92
+
79
93
  `protect` verifies existing account access, repairs private permissions and converts
80
94
  existing plaintext records in place. It verifies preserved content without making
81
- plaintext backups. Restart all DotShare MCP clients and VS Code windows afterwards
82
- so older processes cannot write the previous format. Prior snapshots/backups may
95
+ plaintext backups. Restart all DotShare MCP clients and VS Code windows afterwards,
96
+ then run `dotshare-agent doctor --check-accounts`. Prior snapshots and backups may
83
97
  still contain plaintext; the migration does not securely erase old disk pages.
84
98
 
85
99
  Credential JSON input files must be private (0600 on Unix), regular files owned by
@@ -178,7 +192,8 @@ in the OS keyring are shared between home directories; account IDs should be uni
178
192
  if using several directories. `DOTSHARE_MEDIA_ROOTS` contains allowed image directories
179
193
  separated by the OS path delimiter (`:` on Linux/macOS, `;` on Windows). Each entry
180
194
  must be an absolute path. When it is unset or invalid, local images are disabled and
181
- text-only posts still work. Real paths are checked, including symlink targets.
195
+ text-only posts still work. A relative image path such as `launch.png` is looked up
196
+ inside each root in order. Real paths are checked, including symlink targets.
182
197
  The server never downloads arbitrary social-media URLs or reads credentials from
183
198
  tool arguments. Diagnostics go to stderr; stdout is reserved for MCP JSON.
184
199