getaimeter 0.7.8 → 0.8.0
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/package.json +1 -1
- package/tray.ps1 +9 -4
- package/watcher.js +18 -2
package/package.json
CHANGED
package/tray.ps1
CHANGED
|
@@ -55,10 +55,15 @@ $dashboard.Add_Click({ Start-Process "https://getaimeter.com/dashboard" })
|
|
|
55
55
|
$logs = $menu.Items.Add("View Logs")
|
|
56
56
|
$viewerScript = Join-Path (Split-Path $MyInvocation.MyCommand.Path) 'log-viewer.ps1'
|
|
57
57
|
$logs.Add_Click({
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
58
|
+
# Launch log viewer directly via PowerShell — avoids VBS quoting issues with paths containing spaces
|
|
59
|
+
Start-Process "powershell" -ArgumentList @(
|
|
60
|
+
"-NoProfile",
|
|
61
|
+
"-ExecutionPolicy", "Bypass",
|
|
62
|
+
"-STA",
|
|
63
|
+
"-WindowStyle", "Hidden",
|
|
64
|
+
"-File", $viewerScript,
|
|
65
|
+
"-LogPath", $LogPath
|
|
66
|
+
) -WindowStyle Hidden
|
|
62
67
|
})
|
|
63
68
|
|
|
64
69
|
$menu.Items.Add("-")
|
package/watcher.js
CHANGED
|
@@ -75,8 +75,24 @@ function detectSource(filePath) {
|
|
|
75
75
|
return 'gemini_cli';
|
|
76
76
|
}
|
|
77
77
|
if (normalized.includes('.codex/') || normalized.includes('/codex/')) {
|
|
78
|
-
|
|
79
|
-
|
|
78
|
+
// Codex sessions may come from CLI or VS Code extension.
|
|
79
|
+
// Read session_meta to check originator/source field.
|
|
80
|
+
let codexSource = 'codex_cli';
|
|
81
|
+
try {
|
|
82
|
+
const fd = fs.openSync(filePath, 'r');
|
|
83
|
+
const buf = Buffer.alloc(Math.min(2048, fs.fstatSync(fd).size));
|
|
84
|
+
fs.readSync(fd, buf, 0, buf.length, 0);
|
|
85
|
+
fs.closeSync(fd);
|
|
86
|
+
const firstLine = buf.toString('utf8').split('\n')[0];
|
|
87
|
+
const meta = JSON.parse(firstLine);
|
|
88
|
+
if (meta.type === 'session_meta' && meta.payload) {
|
|
89
|
+
if (meta.payload.source === 'vscode' || meta.payload.originator === 'codex_vscode') {
|
|
90
|
+
codexSource = 'codex_vscode';
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
} catch {}
|
|
94
|
+
_sourceCache.set(filePath, codexSource);
|
|
95
|
+
return codexSource;
|
|
80
96
|
}
|
|
81
97
|
if (normalized.includes('/Cursor/') || normalized.includes('/cursor/') || normalized.includes('.cursor/')) {
|
|
82
98
|
_sourceCache.set(filePath, 'cursor');
|