codewhale.history 2.8.2 → 2.8.4

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 CHANGED
@@ -44,6 +44,10 @@ Lists every tool available in the current session, grouped by category (File I/O
44
44
  Search, Git, Sub-agents, Shell, Planning, etc.), with a brief description of what
45
45
  each tool does. Read-only — no files touched.
46
46
 
47
+ **`//tools help`** or **`//tools readme`** — displays this full README inside any
48
+ CodeWhale session, so you can always reference the command docs without leaving
49
+ the terminal.
50
+
47
51
  ### `//history`
48
52
  Lists all chat sessions for the current workspace. Each session row shows:
49
53
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "codewhale.history",
3
- "version": "2.8.2",
3
+ "version": "2.8.4",
4
4
  "description": "CodeWhale utility commands: session history, tool listing, file snapshot, interactive code quiz — global install",
5
5
  "bin": {
6
6
  "codewhale-history": "./_list_sessions.js",
@@ -13,6 +13,9 @@
13
13
  "instructions.md",
14
14
  "skills"
15
15
  ],
16
+ "scripts": {
17
+ "postinstall": "codewhale-tools-install"
18
+ },
16
19
  "engines": {
17
20
  "node": ">=14"
18
21
  }
@@ -13,6 +13,9 @@ When the user types `//tools`, enumerate every tool available to the model in th
13
13
  3. For each tool, provide the name and a one-line description of what it does
14
14
  4. Present as a readable terminal-friendly list
15
15
 
16
+ ### `//tools help` / `//tools readme`
17
+ When the user types `//tools help` or `//tools readme`, read and display the full tools README from `~/.codewhale/tools-readme.md`. This file is copied during install and contains detailed docs for all four commands: `//tools`, `//history`, `//snapshot`, and `//teach-me`.
18
+
16
19
  ## Notes
17
20
  - Read-only — no files modified or state changed
18
21
  - The tool list is dynamic per-session — do not hardcode it
package/tools-install.js CHANGED
@@ -70,6 +70,17 @@ if (fs.existsSync(instructionsSource)) {
70
70
  console.log(' WARNING: instructions.md not found.');
71
71
  }
72
72
 
73
+ // ── 2b. Copy README for //tools help ───────────────────
74
+ const readmeSource = path.join(sourceDir, 'README.md');
75
+ const readmeDest = path.join(os.homedir(), '.codewhale', 'tools-readme.md');
76
+
77
+ if (fs.existsSync(readmeSource)) {
78
+ fs.copyFileSync(readmeSource, readmeDest);
79
+ console.log(' Copied README.md for //tools help.');
80
+ } else {
81
+ console.log(' WARNING: README.md not found.');
82
+ }
83
+
73
84
  // ── 3. Verify ──────────────────────────────────────────
74
85
  console.log('[3/3] Verifying installation...');
75
86
  let errors = 0;
@@ -79,7 +90,8 @@ const checklist = {
79
90
  'tools skill': path.join(skillsDest, 'tools', 'tools-skill', 'SKILL.md'),
80
91
  'snapshot skill': path.join(skillsDest, 'snapshot', 'SKILL.md'),
81
92
  'teach-me skill': path.join(skillsDest, 'teach-me', 'SKILL.md'),
82
- 'workspace instructions': instructionsDest
93
+ 'workspace instructions': instructionsDest,
94
+ 'tools readme': readmeDest
83
95
  };
84
96
 
85
97
  for (const [name, filePath] of Object.entries(checklist)) {
@@ -94,8 +106,7 @@ for (const [name, filePath] of Object.entries(checklist)) {
94
106
  console.log('');
95
107
  if (errors === 0) {
96
108
  console.log('=== Installation complete! ===');
97
- console.log('Make sure codewhale-history is installed globally: npm install -g <path-to-tools_for_codewhale>');
98
- console.log('Then type //tools, //history, //snapshot, or //teach-me in any CodeWhale session.');
109
+ console.log('Type //tools, //history, //snapshot, or //teach-me in any CodeWhale session.');
99
110
  } else {
100
111
  console.log(`=== Installation finished with ${errors} error(s). ===`);
101
112
  }