@themoltnet/legreffier 0.32.5 → 0.33.1

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.
Files changed (3) hide show
  1. package/README.md +15 -0
  2. package/dist/index.js +12 -3
  3. package/package.json +5 -5
package/README.md CHANGED
@@ -357,6 +357,21 @@ Once inside a coding session, activate the skill:
357
357
  This sets `GIT_CONFIG_GLOBAL` to the agent's gitconfig, verifies the signing
358
358
  key, and confirms readiness. All subsequent git commits use the agent identity.
359
359
 
360
+ LeGreffier keeps warm activation fast with a local cache at
361
+ `.moltnet/<agent>/activation-cache.json`. The cache stores derived activation
362
+ state plus hashes of the env file, gitconfig, credentials, and SSH public key.
363
+ If the hashes still match, activation skips remote identity and diary lookup.
364
+ Transport is still detected per session and is not stored in the cache. If
365
+ anything changes, the skill runs the full ceremony and refreshes the cache.
366
+
367
+ Manual cache commands:
368
+
369
+ ```bash
370
+ moltnet agents activation validate --agent <agent-name> --dir . --json
371
+ moltnet agents activation refresh --agent <agent-name> --dir . --json
372
+ moltnet agents activation clear --agent <agent-name> --dir .
373
+ ```
374
+
360
375
  ## Verification
361
376
 
362
377
  ```bash
package/dist/index.js CHANGED
@@ -7905,6 +7905,10 @@ function buildCodexRules(_agentName) {
7905
7905
  " decision = \"allow\",",
7906
7906
  ")",
7907
7907
  "prefix_rule(",
7908
+ " pattern = [\"moltnet\", \"agents\", \"activation\"],",
7909
+ " decision = \"allow\",",
7910
+ ")",
7911
+ "prefix_rule(",
7908
7912
  " pattern = [\"moltnet\", \"sign\"],",
7909
7913
  " decision = \"allow\",",
7910
7914
  ")",
@@ -7974,11 +7978,13 @@ function buildPermissions(agentName) {
7974
7978
  "Bash(moltnet diary create-signed *)",
7975
7979
  "Bash(moltnet diary verify *)",
7976
7980
  "Bash(moltnet github token *)",
7981
+ "Bash(moltnet agents activation *)",
7977
7982
  "Bash(npx @themoltnet/cli sign *)",
7978
7983
  "Bash(npx @themoltnet/cli diary commit *)",
7979
7984
  "Bash(npx @themoltnet/cli diary create-signed *)",
7980
7985
  "Bash(npx @themoltnet/cli diary verify *)",
7981
7986
  "Bash(npx @themoltnet/cli github token *)",
7987
+ "Bash(npx @themoltnet/cli agents activation *)",
7982
7988
  "Bash(ln -s *)",
7983
7989
  "Bash(echo \"GIT_CONFIG_GLOBAL=*\")",
7984
7990
  `mcp__${agentName}__*`
@@ -8127,7 +8133,8 @@ async function writeEnvFile(opts) {
8127
8133
  [`${opts.prefix}_GITHUB_APP_PRIVATE_KEY_PATH`, q(opts.pemPath)],
8128
8134
  [`${opts.prefix}_GITHUB_APP_INSTALLATION_ID`, q(opts.installationId)],
8129
8135
  ["GIT_CONFIG_GLOBAL", q(`.moltnet/${opts.agentName}/gitconfig`)],
8130
- ["MOLTNET_AGENT_NAME", q(opts.agentName)]
8136
+ ["MOLTNET_AGENT_NAME", q(opts.agentName)],
8137
+ ...opts.fingerprint ? [["MOLTNET_FINGERPRINT", q(opts.fingerprint)]] : []
8131
8138
  ];
8132
8139
  const managedKeys = new Set(managedEntries.map(([k]) => k));
8133
8140
  let existingLines = [];
@@ -8340,7 +8347,8 @@ async function runAgentSetupPhase(opts) {
8340
8347
  clientSecret,
8341
8348
  appId,
8342
8349
  pemPath,
8343
- installationId
8350
+ installationId,
8351
+ fingerprint
8344
8352
  });
8345
8353
  await appendAuthorshipVars(configDir, opts.humanGitIdentity ?? resolveHumanGitIdentity(), opts.commitAuthorship);
8346
8354
  await clearState(configDir);
@@ -9799,7 +9807,8 @@ async function runPortRewritePhase(opts) {
9799
9807
  clientSecret: config.oauth2.client_secret,
9800
9808
  appId: config.github.app_id,
9801
9809
  pemPath: newPem,
9802
- installationId: config.github.installation_id
9810
+ installationId: config.github.installation_id,
9811
+ fingerprint: config.keys.fingerprint
9803
9812
  });
9804
9813
  await appendAuthorshipVars(targetDir, resolveHumanGitIdentity());
9805
9814
  return {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@themoltnet/legreffier",
3
- "version": "0.32.5",
3
+ "version": "0.33.1",
4
4
  "description": "LeGreffier — attribution and measured memory for AI coding agents.",
5
5
  "license": "AGPL-3.0-only",
6
6
  "type": "module",
@@ -32,11 +32,11 @@
32
32
  "typescript": "^5.3.3",
33
33
  "vite": "^8.0.0",
34
34
  "vitest": "^3.0.0",
35
- "@themoltnet/github-agent": "0.23.5",
36
- "@moltnet/crypto-service": "0.1.0",
37
- "@themoltnet/sdk": "0.98.0",
38
35
  "@moltnet/api-client": "0.1.0",
39
- "@themoltnet/design-system": "0.7.2"
36
+ "@themoltnet/design-system": "0.7.2",
37
+ "@themoltnet/github-agent": "0.23.5",
38
+ "@themoltnet/sdk": "0.99.0",
39
+ "@moltnet/crypto-service": "0.1.0"
40
40
  },
41
41
  "nx": {
42
42
  "tags": [