memgineering 0.6.0 → 0.6.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.
package/CHANGELOG.md CHANGED
@@ -11,6 +11,34 @@ language the reader wants. The bilingual rule the monorepo applies to
11
11
 
12
12
  ## [Unreleased]
13
13
 
14
+ ## [0.6.2] — 2026-08-16
15
+
16
+ ### Fixed
17
+
18
+ - **The bundled guidance says which version it is.** Its frontmatter still read
19
+ `0.5.0` while the package shipped 0.6.1 — invisible in a `CLAUDE.md`, where
20
+ that block is stripped before injection, but visible to any tool that loads a
21
+ SKILL.md as a file, and the only answer to "which guidance am I on". It now
22
+ tracks the package version, and a test keeps it there.
23
+
24
+ ## [0.6.1] — 2026-08-16
25
+
26
+ ### Fixed
27
+
28
+ - **`memgineering setup` can change a hook it already installed.** It could
29
+ not, and 0.6.0 depended on it being able to. That release widened the
30
+ before-edit hook so a rule about a command — committing, deleting, deploying
31
+ — could be shown at all, and told people to re-run setup to pick it up.
32
+ Re-running setup did nothing: seeing its own hook already in your settings, it
33
+ reported success and left the old shape in place. So the fix reached only
34
+ machines that had never installed memgineering, and the changelog line telling
35
+ everyone else how to get it was wrong.
36
+
37
+ setup now brings a hook it owns up to the current version's shape, in place —
38
+ no duplicate group, and no rewrite when nothing differs. **If you installed
39
+ 0.6.0, run `memgineering setup` once more and restart the conversation**;
40
+ this time it will take.
41
+
14
42
  ## [0.6.0] — 2026-08-16
15
43
 
16
44
  ### Added
@@ -2,7 +2,7 @@
2
2
  name: memgineering
3
3
  description: Use whenever the user refers to something they told you before, asks what was decided, tells you something worth keeping, or settles something that should hold next time. The memory lives in their own folder and outlives this session; check it before answering from guesswork, and write to it when you learn something durable.
4
4
  type: skill
5
- version: 0.5.0
5
+ version: 0.6.2
6
6
  ---
7
7
 
8
8
  # memgineering
package/dist/index.js CHANGED
@@ -7087,10 +7087,8 @@ async function installHook(spec, tool, dryRun) {
7087
7087
  }
7088
7088
  const hooks = settings["hooks"] ?? {};
7089
7089
  const existingGroups = Array.isArray(hooks[spec.event]) ? [...hooks[spec.event]] : [];
7090
- const already = existingGroups.some((group) => JSON.stringify(group).includes(spec.signature));
7091
- if (already) return "unchanged";
7092
7090
  const matcher = spec.matcher?.[tool.id];
7093
- existingGroups.push({
7091
+ const desired = {
7094
7092
  ...matcher === void 0 ? {} : { matcher },
7095
7093
  /*
7096
7094
  * Two ceilings, and both earn their place. The CLI gives up on its own
@@ -7100,7 +7098,21 @@ async function installHook(spec, tool, dryRun) {
7100
7098
  * start its own timer is still the host's to kill.
7101
7099
  */
7102
7100
  hooks: [{ type: "command", command: spec.command, timeout: HOOK_TIMEOUT_S }]
7103
- });
7101
+ };
7102
+ const sameCommand = (group) => {
7103
+ const entries = group?.hooks;
7104
+ return Array.isArray(entries) && entries.some((h) => h?.command === spec.command);
7105
+ };
7106
+ let at = existingGroups.findIndex(sameCommand);
7107
+ if (at === -1) {
7108
+ at = existingGroups.findIndex((g) => JSON.stringify(g).includes(spec.signature));
7109
+ }
7110
+ if (at === -1) {
7111
+ existingGroups.push(desired);
7112
+ } else {
7113
+ if (JSON.stringify(existingGroups[at]) === JSON.stringify(desired)) return "unchanged";
7114
+ existingGroups[at] = desired;
7115
+ }
7104
7116
  const next = { ...settings, hooks: { ...hooks, [spec.event]: existingGroups } };
7105
7117
  if (!dryRun) {
7106
7118
  await mkdir13(dirname5(settingsPath), { recursive: true });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "memgineering",
3
- "version": "0.6.0",
3
+ "version": "0.6.2",
4
4
  "private": false,
5
5
  "description": "One memory for the AI you connect. Recall, remember, and revise a brain your agents share \u2014 stored in your own folder.",
6
6
  "license": "Apache-2.0",