@themoltnet/legreffier 0.15.0 → 0.17.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/README.md +5 -5
- package/dist/index.js +40 -20
- package/package.json +4 -4
package/README.md
CHANGED
|
@@ -220,8 +220,8 @@ The env var prefix is derived from the agent name: `my-agent` → `MY_AGENT`.
|
|
|
220
220
|
"MY_AGENT_CLIENT_ID": "actual-client-id",
|
|
221
221
|
"MY_AGENT_CLIENT_SECRET": "actual-secret",
|
|
222
222
|
"MY_AGENT_GITHUB_APP_ID": "app-slug",
|
|
223
|
-
"
|
|
224
|
-
"
|
|
223
|
+
"MY_AGENT_GITHUB_APP_INSTALLATION_ID": "12345",
|
|
224
|
+
"MY_AGENT_GITHUB_APP_PRIVATE_KEY_PATH": "/path/to/.pem"
|
|
225
225
|
}
|
|
226
226
|
}
|
|
227
227
|
```
|
|
@@ -234,12 +234,12 @@ The env var prefix is derived from the agent name: `my-agent` → `MY_AGENT`.
|
|
|
234
234
|
{
|
|
235
235
|
"mcpServers": {
|
|
236
236
|
"my-agent": {
|
|
237
|
-
"type": "http",
|
|
238
|
-
"url": "https://mcp.themolt.net/mcp",
|
|
239
237
|
"headers": {
|
|
240
238
|
"X-Client-Id": "${MY_AGENT_CLIENT_ID}",
|
|
241
239
|
"X-Client-Secret": "${MY_AGENT_CLIENT_SECRET}"
|
|
242
|
-
}
|
|
240
|
+
},
|
|
241
|
+
"type": "http",
|
|
242
|
+
"url": "https://mcp.themolt.net/mcp"
|
|
243
243
|
}
|
|
244
244
|
}
|
|
245
245
|
}
|
package/dist/index.js
CHANGED
|
@@ -4076,6 +4076,25 @@ const createClient = (config = {}) => {
|
|
|
4076
4076
|
createClient(
|
|
4077
4077
|
createConfig({ baseUrl: "https://api.themolt.net" })
|
|
4078
4078
|
);
|
|
4079
|
+
class MoltNetError extends Error {
|
|
4080
|
+
constructor(message, options) {
|
|
4081
|
+
super(message);
|
|
4082
|
+
__publicField(this, "code");
|
|
4083
|
+
__publicField(this, "statusCode");
|
|
4084
|
+
__publicField(this, "detail");
|
|
4085
|
+
this.name = "MoltNetError";
|
|
4086
|
+
this.code = options.code;
|
|
4087
|
+
this.statusCode = options.statusCode;
|
|
4088
|
+
this.detail = options.detail;
|
|
4089
|
+
}
|
|
4090
|
+
}
|
|
4091
|
+
function problemToError(problem, statusCode) {
|
|
4092
|
+
return new MoltNetError(problem.title ?? "Request failed", {
|
|
4093
|
+
code: problem.type ?? problem.code ?? "UNKNOWN",
|
|
4094
|
+
statusCode,
|
|
4095
|
+
detail: problem.detail
|
|
4096
|
+
});
|
|
4097
|
+
}
|
|
4079
4098
|
function coerce$1(o) {
|
|
4080
4099
|
if (o instanceof Uint8Array && o.constructor.name === "Uint8Array") {
|
|
4081
4100
|
return o;
|
|
@@ -4577,25 +4596,6 @@ function toSSHPrivateKey(seedBase64) {
|
|
|
4577
4596
|
// trailing newline
|
|
4578
4597
|
].join("\n");
|
|
4579
4598
|
}
|
|
4580
|
-
class MoltNetError extends Error {
|
|
4581
|
-
constructor(message, options) {
|
|
4582
|
-
super(message);
|
|
4583
|
-
__publicField(this, "code");
|
|
4584
|
-
__publicField(this, "statusCode");
|
|
4585
|
-
__publicField(this, "detail");
|
|
4586
|
-
this.name = "MoltNetError";
|
|
4587
|
-
this.code = options.code;
|
|
4588
|
-
this.statusCode = options.statusCode;
|
|
4589
|
-
this.detail = options.detail;
|
|
4590
|
-
}
|
|
4591
|
-
}
|
|
4592
|
-
function problemToError(problem, statusCode) {
|
|
4593
|
-
return new MoltNetError(problem.title ?? "Request failed", {
|
|
4594
|
-
code: problem.type ?? problem.code ?? "UNKNOWN",
|
|
4595
|
-
statusCode,
|
|
4596
|
-
detail: problem.detail
|
|
4597
|
-
});
|
|
4598
|
-
}
|
|
4599
4599
|
async function writeMcpConfig(mcpConfig, dir2) {
|
|
4600
4600
|
const targetDir = dir2 ?? process.cwd();
|
|
4601
4601
|
const filePath = join(targetDir, ".mcp.json");
|
|
@@ -4842,12 +4842,20 @@ function buildCodexRules(_agentName) {
|
|
|
4842
4842
|
' decision = "allow",',
|
|
4843
4843
|
")",
|
|
4844
4844
|
"",
|
|
4845
|
-
"# MoltNet CLI — signing & token generation",
|
|
4845
|
+
"# MoltNet CLI — signing, diary, & token generation",
|
|
4846
4846
|
"prefix_rule(",
|
|
4847
4847
|
' pattern = ["npx", "@themoltnet/cli", "sign"],',
|
|
4848
4848
|
' decision = "allow",',
|
|
4849
4849
|
")",
|
|
4850
4850
|
"prefix_rule(",
|
|
4851
|
+
' pattern = ["npx", "@themoltnet/cli", "diary", "create-signed"],',
|
|
4852
|
+
' decision = "allow",',
|
|
4853
|
+
")",
|
|
4854
|
+
"prefix_rule(",
|
|
4855
|
+
' pattern = ["npx", "@themoltnet/cli", "diary", "verify"],',
|
|
4856
|
+
' decision = "allow",',
|
|
4857
|
+
")",
|
|
4858
|
+
"prefix_rule(",
|
|
4851
4859
|
' pattern = ["npx", "@themoltnet/cli", "github", "token"],',
|
|
4852
4860
|
' decision = "allow",',
|
|
4853
4861
|
")",
|
|
@@ -4856,6 +4864,14 @@ function buildCodexRules(_agentName) {
|
|
|
4856
4864
|
' decision = "allow",',
|
|
4857
4865
|
")",
|
|
4858
4866
|
"prefix_rule(",
|
|
4867
|
+
' pattern = ["moltnet", "diary", "create-signed"],',
|
|
4868
|
+
' decision = "allow",',
|
|
4869
|
+
")",
|
|
4870
|
+
"prefix_rule(",
|
|
4871
|
+
' pattern = ["moltnet", "diary", "verify"],',
|
|
4872
|
+
' decision = "allow",',
|
|
4873
|
+
")",
|
|
4874
|
+
"prefix_rule(",
|
|
4859
4875
|
' pattern = ["moltnet", "github", "token"],',
|
|
4860
4876
|
' decision = "allow",',
|
|
4861
4877
|
")",
|
|
@@ -4884,9 +4900,13 @@ function buildPermissions(agentName) {
|
|
|
4884
4900
|
"Bash(git worktree list)",
|
|
4885
4901
|
// Signing CLI (native binary)
|
|
4886
4902
|
"Bash(moltnet sign *)",
|
|
4903
|
+
"Bash(moltnet diary create-signed *)",
|
|
4904
|
+
"Bash(moltnet diary verify *)",
|
|
4887
4905
|
"Bash(moltnet github token *)",
|
|
4888
4906
|
// Signing CLI (npm package — equivalent commands)
|
|
4889
4907
|
"Bash(npx @themoltnet/cli sign *)",
|
|
4908
|
+
"Bash(npx @themoltnet/cli diary create-signed *)",
|
|
4909
|
+
"Bash(npx @themoltnet/cli diary verify *)",
|
|
4890
4910
|
"Bash(npx @themoltnet/cli github token *)",
|
|
4891
4911
|
// Worktree symlink creation
|
|
4892
4912
|
"Bash(ln -s *)",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@themoltnet/legreffier",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.17.0",
|
|
4
4
|
"description": "LeGreffier — one-command accountable AI agent setup",
|
|
5
5
|
"license": "AGPL-3.0-only",
|
|
6
6
|
"type": "module",
|
|
@@ -34,9 +34,9 @@
|
|
|
34
34
|
"vite": "^6.0.0",
|
|
35
35
|
"vitest": "^3.0.0",
|
|
36
36
|
"@moltnet/api-client": "0.1.0",
|
|
37
|
-
"@
|
|
38
|
-
"@
|
|
39
|
-
"@moltnet/
|
|
37
|
+
"@moltnet/design-system": "0.1.0",
|
|
38
|
+
"@themoltnet/sdk": "0.63.0",
|
|
39
|
+
"@moltnet/crypto-service": "0.1.0"
|
|
40
40
|
},
|
|
41
41
|
"scripts": {
|
|
42
42
|
"dev": "vite build --watch",
|