pi-patch-keeper 1.3.0 → 1.3.2

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 (2) hide show
  1. package/README.md +19 -17
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -63,14 +63,11 @@ pi install npm:pi-patch-keeper
63
63
 
64
64
  ```mermaid
65
65
  flowchart TD
66
- A[factory] --> B[读 settings.json 建指纹]
67
- B --> C[session_start]
68
- C --> D{指纹变化?}
69
- D -->|是| E[通知:手册/结论可能过期]
70
- C --> F{force 顺序错?}
71
- F -->|是| G[备份 + 重排 packages]
72
- C --> H[before_agent_start<br/>比对注入手册版本与磁盘]
73
- H -->|不一致| I[通知 + nextTurn 尾部消息<br/>以磁盘为准]
66
+ A[factory:读 settings.json 建指纹] --> B[session_start]
67
+ A --> C[before_agent_start]
68
+ B -->|指纹变化| D[通知:手册 / 结论可能过期]
69
+ B -->|force 顺序错| E[备份 + 重排 packages]
70
+ C -->|注入版本 vs 磁盘不一致| F[通知 + nextTurn 尾部消息<br/>以磁盘为准]
74
71
  ```
75
72
 
76
73
  ## 原理(小白)
@@ -128,6 +125,15 @@ Config file `~/.pi/patch-keeper.json` (optional); no environment variables.
128
125
  | `~/.pi/patch-keeper-manual.json` | Manual version + content signature |
129
126
  | `~/.pi/agent/settings.json.bak-force-order-*` | Backup before a force-order repair |
130
127
 
128
+ Full config:
129
+
130
+ ```json
131
+ {
132
+ "forceTail": ["npm:pi-rtk-optimizer", "npm:pi-cache-optimizer"]
133
+ }
134
+ ```
135
+
136
+
131
137
  ## Commands
132
138
 
133
139
  | Command | Purpose |
@@ -146,15 +152,11 @@ Config file `~/.pi/patch-keeper.json` (optional); no environment variables.
146
152
 
147
153
  ```mermaid
148
154
  flowchart TD
149
- A[factory] --> B[read settings.json, build fingerprint]
150
- B --> C[session_start]
151
- C --> D{fingerprint changed?}
152
- D -->|yes| E[notify: manuals may be stale]
153
- C --> F{force order wrong?}
154
- F -->|yes| G[backup + reorder packages]
155
- C --> H[before_agent_start<br/>compare injected manual vs disk]
156
- H -->|mismatch| I[notify + nextTurn message<br/>trust disk]
157
-
155
+ A[factory: build fingerprint from settings.json] --> B[session_start]
156
+ A --> C[before_agent_start]
157
+ B -->|fingerprint changed| D[notify: manuals may be stale]
158
+ B -->|force order wrong| E[backup + reorder packages]
159
+ C -->|injected vs disk mismatch| F[notify + nextTurn message<br/>trust disk]
158
160
  ```
159
161
 
160
162
  ## How it works (plain words)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pi-patch-keeper",
3
- "version": "1.3.0",
3
+ "version": "1.3.2",
4
4
  "description": "pi config guards: codemode single-source check, force-order guard (auto-fix), settings fingerprint drift, injected-manual alignment. (PiDeck / third-party source patches are a local-only module, not bundled.)",
5
5
  "type": "module",
6
6
  "license": "MIT",