@getrift/rift 0.1.0-beta.13 → 0.1.0-beta.14
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 +35 -9
- package/dist/src/cli/commands/doctor.d.ts +6 -0
- package/dist/src/cli/commands/doctor.d.ts.map +1 -0
- package/dist/src/cli/commands/doctor.js +183 -0
- package/dist/src/cli/commands/doctor.js.map +1 -0
- package/dist/src/cli/commands/menubar.d.ts +30 -0
- package/dist/src/cli/commands/menubar.d.ts.map +1 -0
- package/dist/src/cli/commands/menubar.js +180 -0
- package/dist/src/cli/commands/menubar.js.map +1 -0
- package/dist/src/cli/commands/onboard.d.ts.map +1 -1
- package/dist/src/cli/commands/onboard.js +37 -30
- package/dist/src/cli/commands/onboard.js.map +1 -1
- package/dist/src/cli/commands/status.d.ts +9 -7
- package/dist/src/cli/commands/status.d.ts.map +1 -1
- package/dist/src/cli/commands/status.js +29 -10
- package/dist/src/cli/commands/status.js.map +1 -1
- package/dist/src/cli/commands/update.d.ts +3 -0
- package/dist/src/cli/commands/update.d.ts.map +1 -1
- package/dist/src/cli/commands/update.js +19 -0
- package/dist/src/cli/commands/update.js.map +1 -1
- package/dist/src/cli/index.d.ts.map +1 -1
- package/dist/src/cli/index.js +4 -0
- package/dist/src/cli/index.js.map +1 -1
- package/dist/src/cli/postinstall-menubar.d.ts +22 -0
- package/dist/src/cli/postinstall-menubar.d.ts.map +1 -0
- package/dist/src/cli/postinstall-menubar.js +39 -0
- package/dist/src/cli/postinstall-menubar.js.map +1 -0
- package/dist/src/diagnostics/doctor.d.ts +106 -0
- package/dist/src/diagnostics/doctor.d.ts.map +1 -0
- package/dist/src/diagnostics/doctor.js +251 -0
- package/dist/src/diagnostics/doctor.js.map +1 -0
- package/dist/src/diagnostics/notify.d.ts +90 -0
- package/dist/src/diagnostics/notify.d.ts.map +1 -0
- package/dist/src/diagnostics/notify.js +177 -0
- package/dist/src/diagnostics/notify.js.map +1 -0
- package/dist/src/diagnostics/repair-prompt.d.ts +49 -0
- package/dist/src/diagnostics/repair-prompt.d.ts.map +1 -0
- package/dist/src/diagnostics/repair-prompt.js +198 -0
- package/dist/src/diagnostics/repair-prompt.js.map +1 -0
- package/dist/src/main.js +43 -4
- package/dist/src/main.js.map +1 -1
- package/dist/src/observability/version-check.d.ts +1 -0
- package/dist/src/observability/version-check.d.ts.map +1 -1
- package/dist/src/observability/version-check.js +2 -1
- package/dist/src/observability/version-check.js.map +1 -1
- package/operator/swiftbar/render-menu.py +444 -0
- package/operator/swiftbar/rift.10s.sh +147 -0
- package/package.json +3 -1
package/README.md
CHANGED
|
@@ -27,6 +27,7 @@ Tout reste sur ta machine, sauf les *embeddings* (envoyés à Voyage AI sous une
|
|
|
27
27
|
| 2 | **Node.js 20.19+** | `node --version` dans Ghostty. Si manquant : [nodejs.org](https://nodejs.org/en/download) (LTS) |
|
|
28
28
|
| 3 | **Codex CLI authentifié** | `codex --version`, puis `codex login` si tu n'as jamais loggé |
|
|
29
29
|
| 4 | **Une clé Voyage AI** | Je te l'envoie en DM (c'est un projet dédié sur mon compte Voyage). Range-la dans 1Password, on la collera pendant l'onboard |
|
|
30
|
+
| 5 | **SwiftBar** | Optionnel mais recommandé pour voir l'état Rift dans la barre de menu. Le script installe le plugin Rift automatiquement ; si l'app manque, ouvre [swiftbar.app](https://swiftbar.app) puis relance `rift menubar install`. |
|
|
30
31
|
|
|
31
32
|
Codex CLI fait tourner le triage et l'extraction de métadonnées — pas besoin de clé OpenAI séparée. La clé Voyage sert *uniquement* aux embeddings.
|
|
32
33
|
|
|
@@ -44,6 +45,7 @@ Ce que fait le script :
|
|
|
44
45
|
- installe le paquet npm `@getrift/rift@beta` globalement ;
|
|
45
46
|
- crée tes dossiers de données sous `~/Library/Application Support/Rift/` ;
|
|
46
47
|
- pose un agent launchd qui lance Rift à chaque session ;
|
|
48
|
+
- installe le plugin Rift pour SwiftBar (menu bar) quand possible ;
|
|
47
49
|
- attend que le daemon réponde sur le port local.
|
|
48
50
|
|
|
49
51
|
**Si on te demande ton mot de passe Mac (`Password:`)**, c'est normal — il faut écrire dans un dossier système pour rendre la commande `rift` disponible partout. Tape ton mot de passe (rien ne s'affiche pendant la frappe — c'est normal sur Unix), `Entrée`.
|
|
@@ -56,18 +58,37 @@ Si ça plante en cours de route, le script restaure ton état précédent et imp
|
|
|
56
58
|
rift onboard
|
|
57
59
|
```
|
|
58
60
|
|
|
59
|
-
L'assistant
|
|
61
|
+
L'assistant t'explique d'abord ce qui reste local et ce qui sort (les *embeddings* vers Voyage), **puis** te guide dans l'ordre réel du wizard :
|
|
60
62
|
|
|
61
|
-
1. **La clé Voyage que je t'ai envoyée.** Colle-la depuis 1Password
|
|
62
|
-
2. **Validation.** Rift fait un embed test pour vérifier la cl
|
|
63
|
+
1. **La clé Voyage que je t'ai envoyée.** L'assistant rappelle à quoi elle sert avant de la demander. Colle-la depuis 1Password — elle ne s'affiche pas pendant la frappe.
|
|
64
|
+
2. **Validation.** Rift fait un embed test pour vérifier la clé, la stocke localement, puis redémarre le service.
|
|
63
65
|
3. **Vérifie que Codex est authentifié.** Si ça échoue, lance `codex login` et relance `rift onboard`. Ou demande à Claude.
|
|
64
|
-
4. **
|
|
65
|
-
5. **
|
|
66
|
+
4. **Sessions détectées.** Rift compte tes sessions Claude Code et Codex CLI existantes.
|
|
67
|
+
5. **Feedback.** Par défaut, les notes restent dans un fichier local JSONL ; le relais n'est activé que via un flag opérateur.
|
|
66
68
|
6. **Garde-fou Claude Code (optionnel).** Si Claude Code est détecté, l'assistant te propose d'installer un *PreToolUse hook* qui force la récupération Rift à commencer par `rift_context_pack` (compact, budgété) avant tout `rift_search`. Évite que l'agent crame ton contexte avec des recherches larges. **Réponds `y`** si tu utilises Claude Code. Désactivable à tout moment via `RIFT_POLICY_DISABLED=1` ou en supprimant l'entrée de `~/.claude/settings.json`.
|
|
69
|
+
7. **Première passe de capture.** Watermarke tes sessions existantes (ne les ingère pas).
|
|
70
|
+
8. **Import optionnel.** L'assistant te propose de déposer un export ChatGPT à importer maintenant (ou `skip`). **Pour la beta : `skip`** — voir la section payante plus bas.
|
|
71
|
+
|
|
72
|
+
> L'onboarding **ne branche aucun client MCP tout seul** et ne te demande pas lesquels connecter. C'est une étape séparée, à faire après l'onboarding (voir juste en dessous).
|
|
67
73
|
|
|
68
74
|
À la fin, l'assistant te dit "Onboarding terminé" et te suggère ta première recherche.
|
|
69
75
|
|
|
70
|
-
|
|
76
|
+
### Brancher Rift à tes apps (MCP)
|
|
77
|
+
|
|
78
|
+
L'onboarding installe et indexe Rift, mais ne le connecte à aucune app. Fais-le ensuite, app par app, avec une commande non-interactive :
|
|
79
|
+
|
|
80
|
+
```sh
|
|
81
|
+
rift mcp install --client=claude-desktop
|
|
82
|
+
```
|
|
83
|
+
|
|
84
|
+
Clients supportés (`--client <id>`) :
|
|
85
|
+
|
|
86
|
+
- `claude-desktop` — l'app Claude pour Mac
|
|
87
|
+
- `claude-code` — l'outil Claude Code en terminal
|
|
88
|
+
- `cursor` — l'éditeur Cursor
|
|
89
|
+
- `codex` — l'outil Codex en terminal
|
|
90
|
+
|
|
91
|
+
Pour tout brancher d'un coup : `rift mcp install --all`. Il faut passer `--client <id>` ou `--all` — sans l'un des deux, la commande s'arrête.
|
|
71
92
|
|
|
72
93
|
> Si tu as déjà fait `rift onboard` avant cette beta, tu peux poser le hook après coup avec `rift hooks install --client claude-code`.
|
|
73
94
|
|
|
@@ -92,18 +113,21 @@ Next: nothing broken. Try rift search "<topic>".
|
|
|
92
113
|
|
|
93
114
|
Les ✓ partout = tout va bien. Si une ligne montre ✗ ou un *Next:* différent de "nothing broken", suis l'instruction qu'il imprime.
|
|
94
115
|
|
|
116
|
+
> La ligne `MCP:` reflète les clients que **tu** as branchés avec `rift mcp install` — l'onboarding n'en connecte aucun automatiquement. Juste après l'onboarding, tu peux n'avoir aucun ✓ ici tant que tu n'as pas lancé cette commande.
|
|
117
|
+
|
|
95
118
|
## Usage quotidien
|
|
96
119
|
|
|
97
|
-
- **Rien à faire.** Le daemon tourne en tâche de fond, ingère tes nouvelles sessions Claude Code / Codex CLI toutes les heures,
|
|
120
|
+
- **Rien à faire.** Le daemon tourne en tâche de fond, ingère tes nouvelles sessions Claude Code / Codex CLI toutes les heures, expose la mémoire via MCP, et le menu bar Rift te montre si tout va bien.
|
|
98
121
|
- **Tester depuis Claude Desktop ou Cursor.** Ouvre une conversation, demande par exemple : *"Rappelle-toi ce qu'on a discuté sur le pricing la semaine dernière, va voir dans Rift"* — Claude/Cursor appellera `rift_search` ou `rift_context_pack` automatiquement et t'affichera ce qu'il trouve.
|
|
99
122
|
- **Rechercher en ligne de commande :** `rift search "comment on a structuré le pricing"`
|
|
100
123
|
- **Forcer une passe de capture maintenant :** `rift capture`
|
|
124
|
+
- **Mettre à jour :** Rift vérifie le tag beta toutes les heures. Si une nouvelle version existe, `rift status`, `rift doctor` et le menu bar affichent `rift update` ; dans le menu bar, clique **Update Rift**.
|
|
101
125
|
|
|
102
126
|
## Vie privée
|
|
103
127
|
|
|
104
128
|
- **Local par défaut.** Tes sessions, métadonnées et la base vectorielle (LanceDB) restent sur ta machine.
|
|
105
129
|
- **Voyage AI.** Seuls les *snippets* envoyés pour embedding partent vers Voyage. Ta clé t'appartient — tu peux la révoquer côté Voyage à tout moment, ce qui coupe l'envoi.
|
|
106
|
-
- **Aucune télémétrie de contenu.** Rift ne m'envoie rien
|
|
130
|
+
- **Aucune télémétrie de contenu.** Rift ne m'envoie rien. La commande `rift feedback --kind=...` écrit ta note dans un JSONL local — elle ne part nulle part. Le *feedback relay* (envoi de la note à Clem) n'existe pas par défaut : il faut le configurer explicitement pendant l'onboarding via `rift onboard --enable-feedback-relay <url>`, et même activé, il ne transmet que la note que tu écris, jamais tes conversations.
|
|
107
131
|
- **Désinstallation propre.** `rift uninstall` enlève le daemon et les entrées MCP. `rift uninstall --purge-data` supprime aussi les données locales.
|
|
108
132
|
|
|
109
133
|
Le contrat de vie privée détaillé est dans `docs/feedback/PRIVACY.md` (livré avec le paquet).
|
|
@@ -136,9 +160,11 @@ Pour déclencher : il me faut un **bon de commande / facture HT signée** par to
|
|
|
136
160
|
| `rift status` dit "daemon: unreachable" | `launchctl kickstart -k gui/$UID/com.getrift.daemon` |
|
|
137
161
|
| Codex CLI auth périmé | `codex login` |
|
|
138
162
|
| Clé Voyage révoquée ou changée | `rift onboard --reconfigure-voyage` |
|
|
163
|
+
| Le menu bar Rift n'apparaît pas | Ouvre SwiftBar, puis lance `rift menubar install` |
|
|
164
|
+
| Une mise à jour est disponible | `rift update` |
|
|
139
165
|
| Rift n'apparaît pas dans Claude Desktop / Cursor | `rift mcp install --client=claude-desktop` (remplace par `codex`, `claude-code`, `cursor` selon le besoin) |
|
|
140
166
|
| Le garde-fou Claude Code te bloque trop souvent | `export RIFT_POLICY_DISABLED=1` dans le shell (désactive le hook le temps de la session), ou enlève l'entrée `rift-policy.mjs` de `~/.claude/settings.json` |
|
|
141
|
-
| Truc bizarre, tu veux me prévenir | `rift feedback --kind=broke --with-status` — capture l'état actuel et
|
|
167
|
+
| Truc bizarre, tu veux me prévenir | `rift feedback --kind=broke --with-status` — capture l'état actuel et l'écrit en local (JSONL). Envoie-moi le fichier, ou copie-colle. |
|
|
142
168
|
|
|
143
169
|
## Désinstaller
|
|
144
170
|
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { Command } from "commander";
|
|
2
|
+
import { type DoctorReport } from "../../diagnostics/doctor.js";
|
|
3
|
+
export declare function makeDoctorCommand(): Command;
|
|
4
|
+
/** Render the human-readable diagnosis. */
|
|
5
|
+
export declare function renderReport(report: DoctorReport): string[];
|
|
6
|
+
//# sourceMappingURL=doctor.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"doctor.d.ts","sourceRoot":"","sources":["../../../../src/cli/commands/doctor.ts"],"names":[],"mappings":"AAmBA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AASpC,OAAO,EAEL,KAAK,YAAY,EAElB,MAAM,6BAA6B,CAAC;AAOrC,wBAAgB,iBAAiB,IAAI,OAAO,CA2E3C;AA6DD,2CAA2C;AAC3C,wBAAgB,YAAY,CAAC,MAAM,EAAE,YAAY,GAAG,MAAM,EAAE,CAqC3D"}
|
|
@@ -0,0 +1,183 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* `rift doctor` — plain-language health diagnosis and repair.
|
|
3
|
+
*
|
|
4
|
+
* Reuses exactly the inputs `rift status` uses (the `/status/friend`
|
|
5
|
+
* payload + local signals) and runs them through the shared `diagnose()`
|
|
6
|
+
* layer, so the two commands never disagree. `rift status` stays the
|
|
7
|
+
* source of truth; `rift doctor` is the "explain what's broken and give
|
|
8
|
+
* me one next action" surface on top of it.
|
|
9
|
+
*
|
|
10
|
+
* rift doctor → plain-language diagnosis
|
|
11
|
+
* rift doctor --json → structured report
|
|
12
|
+
* rift doctor --copy-prompt → redacted repair prompt (Claude)
|
|
13
|
+
* rift doctor --copy-prompt --target=codex
|
|
14
|
+
*
|
|
15
|
+
* With --copy-prompt the prompt is copied to the clipboard (best-effort
|
|
16
|
+
* pbcopy) AND printed to stdout, so it is usable even when the clipboard
|
|
17
|
+
* is unavailable.
|
|
18
|
+
*/
|
|
19
|
+
import { execFileSync } from "node:child_process";
|
|
20
|
+
import { Command } from "commander";
|
|
21
|
+
import { createHttpClient, readToken, resolveBaseUrl, CliError, } from "../http-client.js";
|
|
22
|
+
import { printError, printJson, printText } from "../output.js";
|
|
23
|
+
import { readLocalSignals } from "../status/local-signals.js";
|
|
24
|
+
import { diagnose, } from "../../diagnostics/doctor.js";
|
|
25
|
+
import { buildRepairPrompt, } from "../../diagnostics/repair-prompt.js";
|
|
26
|
+
export function makeDoctorCommand() {
|
|
27
|
+
return new Command("doctor")
|
|
28
|
+
.description("Diagnose Rift in plain language and show one next action")
|
|
29
|
+
.option("--copy-prompt", "Generate a redacted repair prompt to paste into an AI assistant")
|
|
30
|
+
.option("--target <assistant>", "Assistant the repair prompt addresses: claude | codex", "claude")
|
|
31
|
+
.action(async (opts, cmd) => {
|
|
32
|
+
const globalOpts = cmd.optsWithGlobals();
|
|
33
|
+
try {
|
|
34
|
+
const target = normalizeTarget(opts.target);
|
|
35
|
+
const { status, unreachableReason } = await fetchFriendStatus(globalOpts.config);
|
|
36
|
+
const localSignals = readLocalSignals();
|
|
37
|
+
const report = diagnose({
|
|
38
|
+
status,
|
|
39
|
+
...(unreachableReason ? { unreachableReason } : {}),
|
|
40
|
+
localSignals,
|
|
41
|
+
now: Date.now(),
|
|
42
|
+
});
|
|
43
|
+
if (opts.copyPrompt) {
|
|
44
|
+
const prompt = buildRepairPrompt({ report, status, localSignals }, target);
|
|
45
|
+
const copied = copyToClipboard(prompt);
|
|
46
|
+
if (globalOpts.json) {
|
|
47
|
+
printJson({ target, copied_to_clipboard: copied, prompt });
|
|
48
|
+
return;
|
|
49
|
+
}
|
|
50
|
+
printText(copied
|
|
51
|
+
? `Repair prompt for ${target} copied to clipboard. Paste it into ${target}:`
|
|
52
|
+
: `Repair prompt for ${target} (clipboard unavailable — copy it manually):`);
|
|
53
|
+
printText("");
|
|
54
|
+
printText(prompt);
|
|
55
|
+
return;
|
|
56
|
+
}
|
|
57
|
+
// Broken state → non-zero exit so scripts/menus can branch on
|
|
58
|
+
// it. Set this BEFORE any early return so --json and the human
|
|
59
|
+
// path agree on the exit code (a script reading --json must not
|
|
60
|
+
// see "healthy": false alongside a success status).
|
|
61
|
+
if (!report.healthy)
|
|
62
|
+
process.exitCode = 1;
|
|
63
|
+
if (globalOpts.json) {
|
|
64
|
+
printJson(report);
|
|
65
|
+
return;
|
|
66
|
+
}
|
|
67
|
+
for (const line of renderReport(report))
|
|
68
|
+
printText(line);
|
|
69
|
+
}
|
|
70
|
+
catch (err) {
|
|
71
|
+
if (err instanceof CliError) {
|
|
72
|
+
printError(err.message);
|
|
73
|
+
}
|
|
74
|
+
else {
|
|
75
|
+
printError(err instanceof Error ? err.message : String(err));
|
|
76
|
+
}
|
|
77
|
+
process.exitCode = 1;
|
|
78
|
+
}
|
|
79
|
+
});
|
|
80
|
+
}
|
|
81
|
+
function normalizeTarget(raw) {
|
|
82
|
+
const value = (raw ?? "claude").toLowerCase();
|
|
83
|
+
if (value === "claude" || value === "codex")
|
|
84
|
+
return value;
|
|
85
|
+
throw new CliError(`Unknown --target "${raw}". Use --target=claude or --target=codex.`, "invalid");
|
|
86
|
+
}
|
|
87
|
+
/**
|
|
88
|
+
* Fetch `/status/friend`, classifying *why* it failed when it does. A
|
|
89
|
+
* null payload is a valid diagnosis input, but the reason matters: a
|
|
90
|
+
* down daemon, a missing config, and a rejected token each need a
|
|
91
|
+
* different next action, so we never collapse them all into "daemon
|
|
92
|
+
* unreachable" (that would tell a friend to restart a daemon when the
|
|
93
|
+
* real fix is `rift token issue` or `rift onboard`).
|
|
94
|
+
*/
|
|
95
|
+
async function fetchFriendStatus(configPath) {
|
|
96
|
+
let baseUrl;
|
|
97
|
+
try {
|
|
98
|
+
baseUrl = resolveBaseUrl(configPath);
|
|
99
|
+
}
|
|
100
|
+
catch {
|
|
101
|
+
// resolveBaseUrl only throws when the config is absent or invalid.
|
|
102
|
+
return { status: null, unreachableReason: "config_missing" };
|
|
103
|
+
}
|
|
104
|
+
let token;
|
|
105
|
+
try {
|
|
106
|
+
token = await readToken();
|
|
107
|
+
}
|
|
108
|
+
catch {
|
|
109
|
+
// A locked Keychain etc. — an auth-side failure, not a dead daemon.
|
|
110
|
+
return { status: null, unreachableReason: "auth_failed" };
|
|
111
|
+
}
|
|
112
|
+
if (!token)
|
|
113
|
+
return { status: null, unreachableReason: "not_authenticated" };
|
|
114
|
+
try {
|
|
115
|
+
const client = createHttpClient({ baseUrl, token });
|
|
116
|
+
const data = await client.get("/status/friend");
|
|
117
|
+
return { status: data };
|
|
118
|
+
}
|
|
119
|
+
catch (err) {
|
|
120
|
+
return { status: null, unreachableReason: classifyFetchError(err) };
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
/** Map a request failure to the diagnosis reason it implies. */
|
|
124
|
+
function classifyFetchError(err) {
|
|
125
|
+
if (err instanceof CliError) {
|
|
126
|
+
if (err.code === "connection_refused")
|
|
127
|
+
return "connection_refused";
|
|
128
|
+
if (err.code === "unauthorized")
|
|
129
|
+
return "auth_failed";
|
|
130
|
+
}
|
|
131
|
+
return "unknown";
|
|
132
|
+
}
|
|
133
|
+
/** Render the human-readable diagnosis. */
|
|
134
|
+
export function renderReport(report) {
|
|
135
|
+
const lines = [];
|
|
136
|
+
if (report.issues.length === 0) {
|
|
137
|
+
lines.push("Rift is working. Nothing needs attention.");
|
|
138
|
+
return lines;
|
|
139
|
+
}
|
|
140
|
+
const broken = report.issues.filter((i) => i.severity === "broken");
|
|
141
|
+
const warnings = report.issues.filter((i) => i.severity === "warning");
|
|
142
|
+
if (broken.length > 0) {
|
|
143
|
+
lines.push("Rift needs attention.");
|
|
144
|
+
}
|
|
145
|
+
else {
|
|
146
|
+
lines.push("Rift is working, with a few advisories.");
|
|
147
|
+
}
|
|
148
|
+
lines.push("");
|
|
149
|
+
for (const issue of broken) {
|
|
150
|
+
lines.push(`✗ ${issue.title}`);
|
|
151
|
+
lines.push(` ${issue.detail}`);
|
|
152
|
+
lines.push(` → ${issue.nextAction}`);
|
|
153
|
+
lines.push("");
|
|
154
|
+
}
|
|
155
|
+
for (const issue of warnings) {
|
|
156
|
+
lines.push(`• ${issue.title}`);
|
|
157
|
+
lines.push(` → ${issue.nextAction}`);
|
|
158
|
+
lines.push("");
|
|
159
|
+
}
|
|
160
|
+
if (report.primary) {
|
|
161
|
+
lines.push(`Do this first: ${report.primary.nextAction}`);
|
|
162
|
+
lines.push("");
|
|
163
|
+
lines.push("Want an AI to fix it? Run: rift doctor --copy-prompt --target=claude");
|
|
164
|
+
}
|
|
165
|
+
return lines;
|
|
166
|
+
}
|
|
167
|
+
/**
|
|
168
|
+
* Copy text to the macOS clipboard via pbcopy. Returns true on success,
|
|
169
|
+
* false on any failure (non-macOS, pbcopy missing) — the caller still
|
|
170
|
+
* prints the prompt, so a clipboard miss is never fatal.
|
|
171
|
+
*/
|
|
172
|
+
function copyToClipboard(text) {
|
|
173
|
+
if (process.platform !== "darwin")
|
|
174
|
+
return false;
|
|
175
|
+
try {
|
|
176
|
+
execFileSync("pbcopy", [], { input: text });
|
|
177
|
+
return true;
|
|
178
|
+
}
|
|
179
|
+
catch {
|
|
180
|
+
return false;
|
|
181
|
+
}
|
|
182
|
+
}
|
|
183
|
+
//# sourceMappingURL=doctor.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"doctor.js","sourceRoot":"","sources":["../../../../src/cli/commands/doctor.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AACH,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAClD,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EACL,gBAAgB,EAChB,SAAS,EACT,cAAc,EACd,QAAQ,GACT,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAAE,UAAU,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAChE,OAAO,EAAE,gBAAgB,EAAE,MAAM,4BAA4B,CAAC;AAC9D,OAAO,EACL,QAAQ,GAGT,MAAM,6BAA6B,CAAC;AACrC,OAAO,EACL,iBAAiB,GAElB,MAAM,oCAAoC,CAAC;AAG5C,MAAM,UAAU,iBAAiB;IAC/B,OAAO,IAAI,OAAO,CAAC,QAAQ,CAAC;SACzB,WAAW,CAAC,0DAA0D,CAAC;SACvE,MAAM,CACL,eAAe,EACf,iEAAiE,CAClE;SACA,MAAM,CACL,sBAAsB,EACtB,uDAAuD,EACvD,QAAQ,CACT;SACA,MAAM,CACL,KAAK,EACH,IAA+C,EAC/C,GAAG,EACH,EAAE;QACF,MAAM,UAAU,GAAG,GAAG,CAAC,eAAe,EAGrC,CAAC;QACF,IAAI,CAAC;YACH,MAAM,MAAM,GAAG,eAA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Q,KAAK,QAAQ;QAAE,OAAO,KAAK,CAAC;IAChD,IAAI,CAAC;QACH,YAAY,CAAC,QAAQ,EAAE,EAAE,EAAE,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC,CAAC;QAC5C,OAAO,IAAI,CAAC;IACd,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,KAAK,CAAC;IACf,CAAC;AACH,CAAC"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { Command } from "commander";
|
|
2
|
+
export declare const SWIFTBAR_PLUGIN_NAME = "rift.10s.sh";
|
|
3
|
+
export declare const SWIFTBAR_RENDERER_NAME = "render-menu.py";
|
|
4
|
+
export interface MenuBarInstallOptions {
|
|
5
|
+
homeDir?: string;
|
|
6
|
+
pluginDir?: string;
|
|
7
|
+
sourceDir?: string;
|
|
8
|
+
packageRoot?: string;
|
|
9
|
+
platform?: NodeJS.Platform;
|
|
10
|
+
copy?: boolean;
|
|
11
|
+
now?: () => Date;
|
|
12
|
+
}
|
|
13
|
+
export interface MenuBarInstallResult {
|
|
14
|
+
ok: boolean;
|
|
15
|
+
skipped: boolean;
|
|
16
|
+
reason: string | null;
|
|
17
|
+
pluginDir: string;
|
|
18
|
+
pluginPath: string;
|
|
19
|
+
sourceDir: string | null;
|
|
20
|
+
sourcePath: string | null;
|
|
21
|
+
rendererPath: string | null;
|
|
22
|
+
mode: "symlink" | "copy" | null;
|
|
23
|
+
backupPath: string | null;
|
|
24
|
+
swiftBarDetected: boolean;
|
|
25
|
+
transcript: string[];
|
|
26
|
+
}
|
|
27
|
+
export declare function makeMenuBarCommand(): Command;
|
|
28
|
+
export declare function defaultSwiftBarPluginDir(homeDir?: string): string;
|
|
29
|
+
export declare function installMenuBar(opts?: MenuBarInstallOptions): MenuBarInstallResult;
|
|
30
|
+
//# sourceMappingURL=menubar.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"menubar.d.ts","sourceRoot":"","sources":["../../../../src/cli/commands/menubar.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
|
+
* The menu surface lives in `operator/swiftbar/` because it is a tiny
|
|
5
|
+
* operator-adjacent script, but beta users should not have to symlink repo
|
|
6
|
+
* paths by hand. This command links the packaged wrapper into SwiftBar's
|
|
7
|
+
* plugin folder. The wrapper follows the symlink back to the package so the
|
|
8
|
+
* renderer beside it updates whenever `npm install -g @getrift/rift@beta`
|
|
9
|
+
* replaces the package on disk.
|
|
10
|
+
*/
|
|
11
|
+
import fs from "node:fs";
|
|
12
|
+
import os from "node:os";
|
|
13
|
+
import path from "node:path";
|
|
14
|
+
import { fileURLToPath } from "node:url";
|
|
15
|
+
import { Command } from "commander";
|
|
16
|
+
import { printError, printJson, printText } from "../output.js";
|
|
17
|
+
export const SWIFTBAR_PLUGIN_NAME = "rift.10s.sh";
|
|
18
|
+
export const SWIFTBAR_RENDERER_NAME = "render-menu.py";
|
|
19
|
+
export function makeMenuBarCommand() {
|
|
20
|
+
const cmd = new Command("menubar").description("Install and manage the Rift menu bar");
|
|
21
|
+
cmd
|
|
22
|
+
.command("install")
|
|
23
|
+
.description("Install or refresh the SwiftBar menu plugin")
|
|
24
|
+
.option("--plugin-dir <path>", "Override SwiftBar's plugin directory")
|
|
25
|
+
.option("--copy", "Copy scripts instead of symlinking to the packaged files")
|
|
26
|
+
.option("--yes", "Non-interactive install; accepted for install scripts")
|
|
27
|
+
.action((opts, command) => {
|
|
28
|
+
const globalOpts = command.optsWithGlobals();
|
|
29
|
+
let result;
|
|
30
|
+
try {
|
|
31
|
+
const installOpts = {};
|
|
32
|
+
if (opts.pluginDir)
|
|
33
|
+
installOpts.pluginDir = opts.pluginDir;
|
|
34
|
+
if (opts.copy !== undefined)
|
|
35
|
+
installOpts.copy = opts.copy;
|
|
36
|
+
result = installMenuBar(installOpts);
|
|
37
|
+
}
|
|
38
|
+
catch (err) {
|
|
39
|
+
const message = err instanceof Error ? err.message : String(err);
|
|
40
|
+
if (globalOpts.json) {
|
|
41
|
+
printJson({ ok: false, error: message });
|
|
42
|
+
}
|
|
43
|
+
else {
|
|
44
|
+
printError(`Menu bar install failed: ${message}`);
|
|
45
|
+
}
|
|
46
|
+
process.exitCode = 1;
|
|
47
|
+
return;
|
|
48
|
+
}
|
|
49
|
+
if (globalOpts.json) {
|
|
50
|
+
printJson(result);
|
|
51
|
+
}
|
|
52
|
+
else {
|
|
53
|
+
for (const line of result.transcript)
|
|
54
|
+
printText(line);
|
|
55
|
+
}
|
|
56
|
+
if (!result.ok)
|
|
57
|
+
process.exitCode = result.skipped ? 0 : 1;
|
|
58
|
+
});
|
|
59
|
+
return cmd;
|
|
60
|
+
}
|
|
61
|
+
export function defaultSwiftBarPluginDir(homeDir = os.homedir()) {
|
|
62
|
+
return path.join(homeDir, "Library", "Application Support", "SwiftBar", "Plugins");
|
|
63
|
+
}
|
|
64
|
+
export function installMenuBar(opts = {}) {
|
|
65
|
+
const platform = opts.platform ?? process.platform;
|
|
66
|
+
const homeDir = opts.homeDir ?? os.homedir();
|
|
67
|
+
const pluginDir = path.resolve(opts.pluginDir ?? process.env.RIFT_SWIFTBAR_PLUGIN_DIR ?? defaultSwiftBarPluginDir(homeDir));
|
|
68
|
+
const pluginPath = path.join(pluginDir, SWIFTBAR_PLUGIN_NAME);
|
|
69
|
+
const transcript = [];
|
|
70
|
+
const swiftBarDetected = detectSwiftBar(homeDir);
|
|
71
|
+
if (platform !== "darwin") {
|
|
72
|
+
const reason = "SwiftBar menu is macOS-only.";
|
|
73
|
+
return {
|
|
74
|
+
ok: true,
|
|
75
|
+
skipped: true,
|
|
76
|
+
reason,
|
|
77
|
+
pluginDir,
|
|
78
|
+
pluginPath,
|
|
79
|
+
sourceDir: null,
|
|
80
|
+
sourcePath: null,
|
|
81
|
+
rendererPath: null,
|
|
82
|
+
mode: null,
|
|
83
|
+
backupPath: null,
|
|
84
|
+
swiftBarDetected,
|
|
85
|
+
transcript: [`Menu bar skipped: ${reason}`],
|
|
86
|
+
};
|
|
87
|
+
}
|
|
88
|
+
const sourceDir = path.resolve(opts.sourceDir ??
|
|
89
|
+
path.join(opts.packageRoot ?? findPackageRoot(), "operator", "swiftbar"));
|
|
90
|
+
const sourcePath = path.join(sourceDir, SWIFTBAR_PLUGIN_NAME);
|
|
91
|
+
const rendererPath = path.join(sourceDir, SWIFTBAR_RENDERER_NAME);
|
|
92
|
+
assertReadableFile(sourcePath, "SwiftBar wrapper");
|
|
93
|
+
assertReadableFile(rendererPath, "SwiftBar renderer");
|
|
94
|
+
fs.mkdirSync(pluginDir, { recursive: true });
|
|
95
|
+
let backupPath = null;
|
|
96
|
+
const mode = opts.copy ? "copy" : "symlink";
|
|
97
|
+
if (mode === "symlink") {
|
|
98
|
+
backupPath = replaceExistingPlugin(pluginPath, sourcePath, opts.now);
|
|
99
|
+
fs.symlinkSync(sourcePath, pluginPath);
|
|
100
|
+
}
|
|
101
|
+
else {
|
|
102
|
+
backupPath = replaceExistingPlugin(pluginPath, sourcePath, opts.now);
|
|
103
|
+
fs.copyFileSync(sourcePath, pluginPath);
|
|
104
|
+
fs.copyFileSync(rendererPath, path.join(pluginDir, SWIFTBAR_RENDERER_NAME));
|
|
105
|
+
fs.chmodSync(pluginPath, 0o755);
|
|
106
|
+
}
|
|
107
|
+
transcript.push("Menu bar installed.");
|
|
108
|
+
if (swiftBarDetected) {
|
|
109
|
+
transcript.push("If the Rift icon is not visible, open SwiftBar or choose Refresh all.");
|
|
110
|
+
}
|
|
111
|
+
else {
|
|
112
|
+
transcript.push("SwiftBar app was not detected. Install/open SwiftBar to show the Rift icon.");
|
|
113
|
+
}
|
|
114
|
+
return {
|
|
115
|
+
ok: true,
|
|
116
|
+
skipped: false,
|
|
117
|
+
reason: null,
|
|
118
|
+
pluginDir,
|
|
119
|
+
pluginPath,
|
|
120
|
+
sourceDir,
|
|
121
|
+
sourcePath,
|
|
122
|
+
rendererPath,
|
|
123
|
+
mode,
|
|
124
|
+
backupPath,
|
|
125
|
+
swiftBarDetected,
|
|
126
|
+
transcript,
|
|
127
|
+
};
|
|
128
|
+
}
|
|
129
|
+
function assertReadableFile(filePath, label) {
|
|
130
|
+
if (!fs.existsSync(filePath) || !fs.statSync(filePath).isFile()) {
|
|
131
|
+
throw new Error(`${label} missing from package: ${filePath}`);
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
function replaceExistingPlugin(pluginPath, sourcePath, now) {
|
|
135
|
+
let stat;
|
|
136
|
+
try {
|
|
137
|
+
stat = fs.lstatSync(pluginPath);
|
|
138
|
+
}
|
|
139
|
+
catch {
|
|
140
|
+
return null;
|
|
141
|
+
}
|
|
142
|
+
if (stat.isSymbolicLink()) {
|
|
143
|
+
const target = fs.readlinkSync(pluginPath);
|
|
144
|
+
const resolved = path.resolve(path.dirname(pluginPath), target);
|
|
145
|
+
if (resolved === sourcePath) {
|
|
146
|
+
fs.unlinkSync(pluginPath);
|
|
147
|
+
return null;
|
|
148
|
+
}
|
|
149
|
+
fs.unlinkSync(pluginPath);
|
|
150
|
+
return null;
|
|
151
|
+
}
|
|
152
|
+
const stamp = toBackupStamp((now ? now() : new Date()).toISOString());
|
|
153
|
+
const backupPath = `${pluginPath}.bak.${stamp}`;
|
|
154
|
+
fs.renameSync(pluginPath, backupPath);
|
|
155
|
+
return backupPath;
|
|
156
|
+
}
|
|
157
|
+
function toBackupStamp(iso) {
|
|
158
|
+
return iso.replace(/[:.]/g, "-");
|
|
159
|
+
}
|
|
160
|
+
function detectSwiftBar(homeDir) {
|
|
161
|
+
return [
|
|
162
|
+
"/Applications/SwiftBar.app",
|
|
163
|
+
path.join(homeDir, "Applications", "SwiftBar.app"),
|
|
164
|
+
].some((candidate) => fs.existsSync(candidate));
|
|
165
|
+
}
|
|
166
|
+
function findPackageRoot() {
|
|
167
|
+
let dir = path.dirname(fileURLToPath(import.meta.url));
|
|
168
|
+
for (let i = 0; i < 8; i += 1) {
|
|
169
|
+
if (fs.existsSync(path.join(dir, "package.json")) &&
|
|
170
|
+
fs.existsSync(path.join(dir, "operator", "swiftbar", SWIFTBAR_PLUGIN_NAME))) {
|
|
171
|
+
return dir;
|
|
172
|
+
}
|
|
173
|
+
const parent = path.dirname(dir);
|
|
174
|
+
if (parent === dir)
|
|
175
|
+
break;
|
|
176
|
+
dir = parent;
|
|
177
|
+
}
|
|
178
|
+
throw new Error("Could not locate packaged SwiftBar assets.");
|
|
179
|
+
}
|
|
180
|
+
//# sourceMappingURL=menubar.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"menubar.js","sourceRoot":"","sources":["../../../../src/cli/commands/menubar.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,OAAO,EAAE,MAAM,SAAS,CAAC;AACzB,OAAO,EAAE,MAAM,SAAS,CAAC;AACzB,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AACzC,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,UAAU,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAEhE,MAAM,CAAC,MAAM,oBAAoB,GAAG,aAAa,CAAC;AAClD,MAAM,CAAC,MAAM,sBAAsB,GAAG,gBAAgB,CAAC;AAiCvD,MAAM,UAAU,kBAAkB;IAChC,MAAM,GAAG,GAAG,IAAI,OAAO,CAAC,SAAS,CAAC,CAAC,WAAW,CAAC,sCAAsC,CAAC,CAAC;IAEvF,GAAG;SACA,OAAO,CAAC,SAAS,CAAC;SAClB,WAAW,CAAC,6CAA6C,CAAC;SAC1D,MAAM,CAAC,qBAAqB,EAAE,sCAAsC,CAAC;SACrE,MAAM,CAAC,QAAQ,EAAE,0DAA0D,CAAC;SAC5E,MAAM,CAAC,OAAO,EAAE,uDAAuD,CAAC;SACxE,MAAM,CAAC,CAAC,IAA8B,EAAE,OAAO,EAAE,EAAE;QAClD,MAAM,UAAU,GAAG,OAAO,CAAC,eAAe,EAAwB,CAAC;QACnE,IAAI,MAA4B,CAAC;QACjC,IAAI,CAAC;YACH,MAAM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ceRoot":"","sources":["../../../../src/cli/commands/onboard.ts"],"names":[],"mappings":"AA2BA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AASpC,OAAO,EAEL,WAAW,EACZ,MAAM,2BAA2B,CAAC;AAGnC,OAAO,EAAE,iBAAiB,EAAE,MAAM,qCAAqC,CAAC;AACxE,OAAO,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAC;AAoB5D;;;;;;;;;;;;;;GAcG;AACH,UAAU,WAAW;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAC7B,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,YAAY,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC;IAChC,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,GAAG,CAAC,EAAE,OAAO,CAAC;IACd,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,YAAY,CAAC,EAAE,OAAO,CAAC;IAKvB,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,cAAc,CAAC,EAAE,OAAO,CAAC;CAC1B;AAED;;;;GAIG;AACH,wBAAgB,KAAK,CAAC,CAAC,SAAS,MAAM,WAAW,EAAE,CAAC,SAAS,MAAM,WAAW,EAC5E,IAAI,EAAE,WAAW,EACjB,WAAW,EAAE,CAAC,EACd,QAAQ,EAAE,CAAC,GACV,OAAO,CAET;AAqBD,wBAAgB,kBAAkB,IAAI,OAAO,CA0C5C;
|
|
1
|
+
{"version":3,"file":"onboard.d.ts","sourceRoot":"","sources":["../../../../src/cli/commands/onboard.ts"],"names":[],"mappings":"AA2BA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,C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