gramatr 0.3.64 → 0.3.65
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/bin/install.ts +11 -0
- package/bin/lib/config.ts +4 -1
- package/package.json +1 -1
package/bin/install.ts
CHANGED
|
@@ -282,6 +282,14 @@ function installClientFiles(): void {
|
|
|
282
282
|
copyFileIfExists(join(SCRIPT_DIR, 'bin/statusline.ts'), join(CLIENT_DIR, 'bin/statusline.ts'), true);
|
|
283
283
|
copyFileIfExists(join(SCRIPT_DIR, 'bin/gmtr-login.ts'), join(CLIENT_DIR, 'bin/gmtr-login.ts'), true);
|
|
284
284
|
copyFileIfExists(join(SCRIPT_DIR, 'bin/render-claude-hooks.ts'), join(CLIENT_DIR, 'bin/render-claude-hooks.ts'), true);
|
|
285
|
+
|
|
286
|
+
// Bin lib helpers (statusline shim depends on these — see #495)
|
|
287
|
+
// Copies git.ts, config.ts, stdin.ts and any future helpers without enumerating each file.
|
|
288
|
+
const binLibSrc = join(SCRIPT_DIR, 'bin', 'lib');
|
|
289
|
+
if (existsSync(binLibSrc)) {
|
|
290
|
+
copyDir(binLibSrc, join(CLIENT_DIR, 'bin', 'lib'));
|
|
291
|
+
log('OK Installed bin/lib (statusline shim helpers)');
|
|
292
|
+
}
|
|
285
293
|
log('OK Installed bin (statusline, gmtr-login, render-claude-hooks)');
|
|
286
294
|
|
|
287
295
|
// Core dependencies (routing.ts required by GMTRPromptEnricher hook)
|
|
@@ -596,6 +604,9 @@ function verify(url: string, token: string): boolean {
|
|
|
596
604
|
'core/routing.ts',
|
|
597
605
|
'bin/statusline.ts',
|
|
598
606
|
'bin/gmtr-login.ts',
|
|
607
|
+
'bin/lib/git.ts',
|
|
608
|
+
'bin/lib/config.ts',
|
|
609
|
+
'bin/lib/stdin.ts',
|
|
599
610
|
'CLAUDE.md',
|
|
600
611
|
]) {
|
|
601
612
|
check(existsSync(join(CLIENT_DIR, f)), f, `${f} MISSING`);
|
package/bin/lib/config.ts
CHANGED
|
@@ -39,10 +39,13 @@ function readGmtrJson(): Record<string, any> | null {
|
|
|
39
39
|
export function getGramatrConfig(): GramatrConfig {
|
|
40
40
|
const json = readGmtrJson();
|
|
41
41
|
|
|
42
|
-
const
|
|
42
|
+
const rawUrl =
|
|
43
43
|
process.env.GMTR_URL ||
|
|
44
44
|
(typeof json?.url === 'string' && json.url) ||
|
|
45
45
|
DEFAULT_URL;
|
|
46
|
+
// GMTR_URL is conventionally the MCP endpoint (e.g. https://api.gramatr.com/mcp).
|
|
47
|
+
// REST calls need the API base — strip a trailing /mcp segment.
|
|
48
|
+
const url = (rawUrl as string).replace(/\/mcp\/?$/, '');
|
|
46
49
|
|
|
47
50
|
const token =
|
|
48
51
|
process.env.GMTR_TOKEN ||
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "gramatr",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.65",
|
|
4
4
|
"description": "grāmatr — context engineering layer for AI coding agents. Every prompt gets a pre-computed intelligence packet: decision routing, capability audit, behavioral directives, memory pre-load, and ISC scaffolds. Continuity across sessions for Claude Code, Codex, and Gemini CLI.",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE",
|
|
6
6
|
"type": "module",
|