Pairs with claudemesh-2's new /join/[token] landing page. Users can now paste a clickable HTTPS URL instead of the dev-only ic:// scheme. apps/cli/src/invite/parse.ts — new extractInviteToken() handles four input formats before handing the raw base64url token to the existing parseInviteLink pipeline: - https://claudemesh.com/join/<token> (primary, clickable) - https://claudemesh.com/<locale>/join/<token> (i18n prefix) - ic://join/<token> (still supported, dev) - <raw-token> (last resort: bare base64url) User-facing strings updated to the HTTPS form: - cli help: "join <url>" - install success message - list (no-meshes) hint - MCP server "no meshes" error - README.md primary example - docs/QUICKSTART.md Path A + Path B Verified extractInviteToken() on all 4 formats — each returns the same base64url token → same broker /join lookup. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
31 lines
956 B
TypeScript
31 lines
956 B
TypeScript
/**
|
|
* `claudemesh list` — show all joined meshes + their status.
|
|
*/
|
|
|
|
import { loadConfig, getConfigPath } from "../state/config";
|
|
|
|
export function runList(): void {
|
|
const config = loadConfig();
|
|
if (config.meshes.length === 0) {
|
|
console.log("No meshes joined yet.");
|
|
console.log("");
|
|
console.log(
|
|
"Join one with: claudemesh join https://claudemesh.com/join/<token>",
|
|
);
|
|
console.log(`Config file: ${getConfigPath()}`);
|
|
return;
|
|
}
|
|
console.log(`Joined meshes (${config.meshes.length}):`);
|
|
console.log("");
|
|
for (const m of config.meshes) {
|
|
console.log(` ${m.name} (${m.slug})`);
|
|
console.log(` mesh id: ${m.meshId}`);
|
|
console.log(` member id: ${m.memberId}`);
|
|
console.log(` pubkey: ${m.pubkey.slice(0, 16)}…`);
|
|
console.log(` broker: ${m.brokerUrl}`);
|
|
console.log(` joined: ${m.joinedAt}`);
|
|
console.log("");
|
|
}
|
|
console.log(`Config: ${getConfigPath()}`);
|
|
}
|