docs-for-me 0.1.1 → 0.1.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/README.md +230 -230
- package/package.json +3 -3
- package/prebuilt/win32-x64/docs-for-me.exe +0 -0
- /package/bin/{docs-for-me.cjs → docs-for-me} +0 -0
package/README.md
CHANGED
|
@@ -1,230 +1,230 @@
|
|
|
1
|
-
<p align="center">
|
|
2
|
-
<img src="https://i.pinimg.com/736x/7a/6d/a5/7a6da5d2962db34846138e08e2932f01.jpg" alt="docs-for-me logo" width="220">
|
|
3
|
-
</p>
|
|
4
|
-
|
|
5
|
-
<h1 align="center">docs-for-me</h1>
|
|
6
|
-
|
|
7
|
-
<p align="center">
|
|
8
|
-
A CLI that creates programmer-friendly guides for files, folders, and Git changes.
|
|
9
|
-
</p>
|
|
10
|
-
|
|
11
|
-
It is meant for the everyday developer moment where you want to know:
|
|
12
|
-
|
|
13
|
-
- What is in this file?
|
|
14
|
-
- What does this folder contain?
|
|
15
|
-
- What did I change before I commit?
|
|
16
|
-
- What commit message can I copy after reviewing the changes?
|
|
17
|
-
|
|
18
|
-
The output is Markdown, so it can be read in a terminal, saved beside a project,
|
|
19
|
-
or deleted after review.
|
|
20
|
-
|
|
21
|
-
## Install
|
|
22
|
-
|
|
23
|
-
Install it with npm:
|
|
24
|
-
|
|
25
|
-
```powershell
|
|
26
|
-
npm install -g docs-for-me
|
|
27
|
-
```
|
|
28
|
-
|
|
29
|
-
Then run it anywhere:
|
|
30
|
-
|
|
31
|
-
```powershell
|
|
32
|
-
docs-for-me --help
|
|
33
|
-
docs-for-me changes --ai none --out changes-guide.md
|
|
34
|
-
```
|
|
35
|
-
|
|
36
|
-
You can also install it inside one project:
|
|
37
|
-
|
|
38
|
-
```powershell
|
|
39
|
-
npm install --save-dev docs-for-me
|
|
40
|
-
npm exec docs-for-me changes --ai none --out changes-guide.md
|
|
41
|
-
```
|
|
42
|
-
|
|
43
|
-
For a one-time trial without installing globally:
|
|
44
|
-
|
|
45
|
-
```powershell
|
|
46
|
-
npx docs-for-me --help
|
|
47
|
-
```
|
|
48
|
-
|
|
49
|
-
Important: `npx docs-for-me` runs the package once. It does not permanently add
|
|
50
|
-
`docs-for-me` as a command. If you want to type `docs-for-me ...` directly,
|
|
51
|
-
install it globally with `npm install -g docs-for-me`.
|
|
52
|
-
|
|
53
|
-
Users do not need to install Python, pip, or pipx.
|
|
54
|
-
|
|
55
|
-
The first npm release ships with a bundled Windows x64 executable. macOS and
|
|
56
|
-
Linux builds can be added after the Windows release flow is stable.
|
|
57
|
-
|
|
58
|
-
## What It Does
|
|
59
|
-
|
|
60
|
-
`docs-for-me` supports three main tasks:
|
|
61
|
-
|
|
62
|
-
```bash
|
|
63
|
-
docs-for-me file <path>
|
|
64
|
-
docs-for-me folder <path>
|
|
65
|
-
docs-for-me changes
|
|
66
|
-
```
|
|
67
|
-
|
|
68
|
-
It has two modes:
|
|
69
|
-
|
|
70
|
-
- `--ai none` uses local static analysis and Git diff parsing.
|
|
71
|
-
- `--ai opencode` asks OpenCode to write a fuller guide.
|
|
72
|
-
|
|
73
|
-
Static mode is useful when you want quick local output. OpenCode mode is useful
|
|
74
|
-
when you want a more natural explanation.
|
|
75
|
-
|
|
76
|
-
## Basic Usage
|
|
77
|
-
|
|
78
|
-
Document one file:
|
|
79
|
-
|
|
80
|
-
```powershell
|
|
81
|
-
docs-for-me file "app/(dashboard)/bookings/page.tsx" --ai none --out bookings-doc.md
|
|
82
|
-
```
|
|
83
|
-
|
|
84
|
-
Document one folder:
|
|
85
|
-
|
|
86
|
-
```powershell
|
|
87
|
-
docs-for-me folder app --ai none --out app-docs.md
|
|
88
|
-
```
|
|
89
|
-
|
|
90
|
-
Explain unstaged Git changes:
|
|
91
|
-
|
|
92
|
-
```powershell
|
|
93
|
-
docs-for-me changes --ai none --out changes-guide.md
|
|
94
|
-
```
|
|
95
|
-
|
|
96
|
-
Explain staged Git changes:
|
|
97
|
-
|
|
98
|
-
```powershell
|
|
99
|
-
docs-for-me changes --staged --ai none --out changes-guide.md
|
|
100
|
-
```
|
|
101
|
-
|
|
102
|
-
Compare changes since a branch or ref:
|
|
103
|
-
|
|
104
|
-
```powershell
|
|
105
|
-
docs-for-me changes --since main --ai none --out changes-guide.md
|
|
106
|
-
```
|
|
107
|
-
|
|
108
|
-
## OpenCode Mode
|
|
109
|
-
|
|
110
|
-
OpenCode mode uses the `opencode` CLI as the AI provider.
|
|
111
|
-
|
|
112
|
-
First, make sure OpenCode works:
|
|
113
|
-
|
|
114
|
-
```powershell
|
|
115
|
-
opencode run "Say hello in one sentence."
|
|
116
|
-
```
|
|
117
|
-
|
|
118
|
-
Then run:
|
|
119
|
-
|
|
120
|
-
```powershell
|
|
121
|
-
docs-for-me file "app/(dashboard)/bookings/page.tsx" --ai opencode --out bookings-ai-doc.md
|
|
122
|
-
```
|
|
123
|
-
|
|
124
|
-
Or for Git changes:
|
|
125
|
-
|
|
126
|
-
```powershell
|
|
127
|
-
docs-for-me changes --ai opencode --out changes-ai-guide.md
|
|
128
|
-
```
|
|
129
|
-
|
|
130
|
-
When OpenCode is working, the generated Markdown should not contain:
|
|
131
|
-
|
|
132
|
-
```markdown
|
|
133
|
-
- **AI:** unavailable or disabled (`opencode`)
|
|
134
|
-
```
|
|
135
|
-
|
|
136
|
-
## Contributor Setup
|
|
137
|
-
|
|
138
|
-
The core CLI is written in Python, but npm is the user-facing package path.
|
|
139
|
-
Use this setup only when developing `docs-for-me` itself:
|
|
140
|
-
|
|
141
|
-
```powershell
|
|
142
|
-
python -m venv .venv
|
|
143
|
-
.venv\Scripts\activate
|
|
144
|
-
pip install -e . pytest
|
|
145
|
-
pytest
|
|
146
|
-
```
|
|
147
|
-
|
|
148
|
-
To build the Windows executable that the npm package runs:
|
|
149
|
-
|
|
150
|
-
```powershell
|
|
151
|
-
npm run build:exe:win
|
|
152
|
-
```
|
|
153
|
-
|
|
154
|
-
Then test the npm wrapper locally:
|
|
155
|
-
|
|
156
|
-
```powershell
|
|
157
|
-
npm run test:npm-local
|
|
158
|
-
```
|
|
159
|
-
|
|
160
|
-
The npm wrapper expects the executable here:
|
|
161
|
-
|
|
162
|
-
```text
|
|
163
|
-
prebuilt/win32-x64/docs-for-me.exe
|
|
164
|
-
```
|
|
165
|
-
|
|
166
|
-
When publishing to npm, that executable is included so users can run
|
|
167
|
-
`docs-for-me ...` after `npm install -g docs-for-me` without setting up Python.
|
|
168
|
-
|
|
169
|
-
If that line appears, `docs-for-me` fell back to static mode.
|
|
170
|
-
|
|
171
|
-
## Git Changes Guide
|
|
172
|
-
|
|
173
|
-
The `changes` command is designed for pre-commit review. It summarizes the diff,
|
|
174
|
-
lists changed files, explains what the changes appear to do, and includes a
|
|
175
|
-
copy-paste-ready commit message.
|
|
176
|
-
|
|
177
|
-
Example output includes:
|
|
178
|
-
|
|
179
|
-
```text
|
|
180
|
-
update: search behavior and plan limits
|
|
181
|
-
```
|
|
182
|
-
|
|
183
|
-
Review the generated guide before committing. The guide is meant to save time,
|
|
184
|
-
not replace your own final check.
|
|
185
|
-
|
|
186
|
-
## Progress Messages
|
|
187
|
-
|
|
188
|
-
Commands print progress messages so long-running AI calls do not look frozen:
|
|
189
|
-
|
|
190
|
-
```text
|
|
191
|
-
[ 0.0s] Reading file: app/(dashboard)/bookings/page.tsx
|
|
192
|
-
[ 0.0s] Preparing documentation with provider: opencode
|
|
193
|
-
[ 0.0s] Waiting for AI response. This can take a moment...
|
|
194
|
-
[ 5.0s] OpenCode is reading the file and prompt...
|
|
195
|
-
[ 10.0s] OpenCode is drafting the guide...
|
|
196
|
-
```
|
|
197
|
-
|
|
198
|
-
Hide progress messages with:
|
|
199
|
-
|
|
200
|
-
```powershell
|
|
201
|
-
docs-for-me file README.md --quiet
|
|
202
|
-
```
|
|
203
|
-
|
|
204
|
-
## Privacy
|
|
205
|
-
|
|
206
|
-
`--ai none` runs locally and does not call an AI provider.
|
|
207
|
-
|
|
208
|
-
`--ai opencode` sends the relevant file contents or Git diff to OpenCode and to
|
|
209
|
-
whatever model/provider OpenCode is configured to use. Do not use AI mode on
|
|
210
|
-
private or sensitive code unless you are comfortable with that provider handling
|
|
211
|
-
the content.
|
|
212
|
-
|
|
213
|
-
## Current Provider Support
|
|
214
|
-
|
|
215
|
-
Today:
|
|
216
|
-
|
|
217
|
-
- `none`
|
|
218
|
-
- `opencode`
|
|
219
|
-
|
|
220
|
-
The code is provider-based, so more providers can be added later.
|
|
221
|
-
|
|
222
|
-
## Project Status
|
|
223
|
-
|
|
224
|
-
`docs-for-me` is early-stage. It is published on npm for Windows x64 first.
|
|
225
|
-
|
|
226
|
-
Good next steps:
|
|
227
|
-
|
|
228
|
-
- add config file support
|
|
229
|
-
- add more AI providers
|
|
230
|
-
- add macOS and Linux npm builds
|
|
1
|
+
<p align="center">
|
|
2
|
+
<img src="https://i.pinimg.com/736x/7a/6d/a5/7a6da5d2962db34846138e08e2932f01.jpg" alt="docs-for-me logo" width="220">
|
|
3
|
+
</p>
|
|
4
|
+
|
|
5
|
+
<h1 align="center">docs-for-me</h1>
|
|
6
|
+
|
|
7
|
+
<p align="center">
|
|
8
|
+
A CLI that creates programmer-friendly guides for files, folders, and Git changes.
|
|
9
|
+
</p>
|
|
10
|
+
|
|
11
|
+
It is meant for the everyday developer moment where you want to know:
|
|
12
|
+
|
|
13
|
+
- What is in this file?
|
|
14
|
+
- What does this folder contain?
|
|
15
|
+
- What did I change before I commit?
|
|
16
|
+
- What commit message can I copy after reviewing the changes?
|
|
17
|
+
|
|
18
|
+
The output is Markdown, so it can be read in a terminal, saved beside a project,
|
|
19
|
+
or deleted after review.
|
|
20
|
+
|
|
21
|
+
## Install
|
|
22
|
+
|
|
23
|
+
Install it with npm:
|
|
24
|
+
|
|
25
|
+
```powershell
|
|
26
|
+
npm install -g docs-for-me
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
Then run it anywhere:
|
|
30
|
+
|
|
31
|
+
```powershell
|
|
32
|
+
docs-for-me --help
|
|
33
|
+
docs-for-me changes --ai none --out changes-guide.md
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
You can also install it inside one project:
|
|
37
|
+
|
|
38
|
+
```powershell
|
|
39
|
+
npm install --save-dev docs-for-me
|
|
40
|
+
npm exec docs-for-me changes --ai none --out changes-guide.md
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
For a one-time trial without installing globally:
|
|
44
|
+
|
|
45
|
+
```powershell
|
|
46
|
+
npx docs-for-me --help
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
Important: `npx docs-for-me` runs the package once. It does not permanently add
|
|
50
|
+
`docs-for-me` as a command. If you want to type `docs-for-me ...` directly,
|
|
51
|
+
install it globally with `npm install -g docs-for-me`.
|
|
52
|
+
|
|
53
|
+
Users do not need to install Python, pip, or pipx.
|
|
54
|
+
|
|
55
|
+
The first npm release ships with a bundled Windows x64 executable. macOS and
|
|
56
|
+
Linux builds can be added after the Windows release flow is stable.
|
|
57
|
+
|
|
58
|
+
## What It Does
|
|
59
|
+
|
|
60
|
+
`docs-for-me` supports three main tasks:
|
|
61
|
+
|
|
62
|
+
```bash
|
|
63
|
+
docs-for-me file <path>
|
|
64
|
+
docs-for-me folder <path>
|
|
65
|
+
docs-for-me changes
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
It has two modes:
|
|
69
|
+
|
|
70
|
+
- `--ai none` uses local static analysis and Git diff parsing.
|
|
71
|
+
- `--ai opencode` asks OpenCode to write a fuller guide.
|
|
72
|
+
|
|
73
|
+
Static mode is useful when you want quick local output. OpenCode mode is useful
|
|
74
|
+
when you want a more natural explanation.
|
|
75
|
+
|
|
76
|
+
## Basic Usage
|
|
77
|
+
|
|
78
|
+
Document one file:
|
|
79
|
+
|
|
80
|
+
```powershell
|
|
81
|
+
docs-for-me file "app/(dashboard)/bookings/page.tsx" --ai none --out bookings-doc.md (--out is the output/ file name of your docs)
|
|
82
|
+
```
|
|
83
|
+
|
|
84
|
+
Document one folder:
|
|
85
|
+
|
|
86
|
+
```powershell
|
|
87
|
+
docs-for-me folder app --ai none --out app-docs.md
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
Explain unstaged Git changes:
|
|
91
|
+
|
|
92
|
+
```powershell
|
|
93
|
+
docs-for-me changes --ai none --out changes-guide.md
|
|
94
|
+
```
|
|
95
|
+
|
|
96
|
+
Explain staged Git changes:
|
|
97
|
+
|
|
98
|
+
```powershell
|
|
99
|
+
docs-for-me changes --staged --ai none --out changes-guide.md
|
|
100
|
+
```
|
|
101
|
+
|
|
102
|
+
Compare changes since a branch or ref:
|
|
103
|
+
|
|
104
|
+
```powershell
|
|
105
|
+
docs-for-me changes --since main --ai none --out changes-guide.md
|
|
106
|
+
```
|
|
107
|
+
|
|
108
|
+
## OpenCode Mode
|
|
109
|
+
|
|
110
|
+
OpenCode mode uses the `opencode` CLI as the AI provider.
|
|
111
|
+
|
|
112
|
+
First, make sure OpenCode works:
|
|
113
|
+
|
|
114
|
+
```powershell
|
|
115
|
+
opencode run "Say hello in one sentence."
|
|
116
|
+
```
|
|
117
|
+
|
|
118
|
+
Then run:
|
|
119
|
+
|
|
120
|
+
```powershell
|
|
121
|
+
docs-for-me file "app/(dashboard)/bookings/page.tsx" --ai opencode --out bookings-ai-doc.md
|
|
122
|
+
```
|
|
123
|
+
|
|
124
|
+
Or for Git changes:
|
|
125
|
+
|
|
126
|
+
```powershell
|
|
127
|
+
docs-for-me changes --ai opencode --out changes-ai-guide.md
|
|
128
|
+
```
|
|
129
|
+
|
|
130
|
+
When OpenCode is working, the generated Markdown should not contain:
|
|
131
|
+
|
|
132
|
+
```markdown
|
|
133
|
+
- **AI:** unavailable or disabled (`opencode`)
|
|
134
|
+
```
|
|
135
|
+
|
|
136
|
+
## Contributor Setup
|
|
137
|
+
|
|
138
|
+
The core CLI is written in Python, but npm is the user-facing package path.
|
|
139
|
+
Use this setup only when developing `docs-for-me` itself:
|
|
140
|
+
|
|
141
|
+
```powershell
|
|
142
|
+
python -m venv .venv
|
|
143
|
+
.venv\Scripts\activate
|
|
144
|
+
pip install -e . pytest
|
|
145
|
+
pytest
|
|
146
|
+
```
|
|
147
|
+
|
|
148
|
+
To build the Windows executable that the npm package runs:
|
|
149
|
+
|
|
150
|
+
```powershell
|
|
151
|
+
npm run build:exe:win
|
|
152
|
+
```
|
|
153
|
+
|
|
154
|
+
Then test the npm wrapper locally:
|
|
155
|
+
|
|
156
|
+
```powershell
|
|
157
|
+
npm run test:npm-local
|
|
158
|
+
```
|
|
159
|
+
|
|
160
|
+
The npm wrapper expects the executable here:
|
|
161
|
+
|
|
162
|
+
```text
|
|
163
|
+
prebuilt/win32-x64/docs-for-me.exe
|
|
164
|
+
```
|
|
165
|
+
|
|
166
|
+
When publishing to npm, that executable is included so users can run
|
|
167
|
+
`docs-for-me ...` after `npm install -g docs-for-me` without setting up Python.
|
|
168
|
+
|
|
169
|
+
If that line appears, `docs-for-me` fell back to static mode.
|
|
170
|
+
|
|
171
|
+
## Git Changes Guide
|
|
172
|
+
|
|
173
|
+
The `changes` command is designed for pre-commit review. It summarizes the diff,
|
|
174
|
+
lists changed files, explains what the changes appear to do, and includes a
|
|
175
|
+
copy-paste-ready commit message.
|
|
176
|
+
|
|
177
|
+
Example output includes:
|
|
178
|
+
|
|
179
|
+
```text
|
|
180
|
+
update: search behavior and plan limits
|
|
181
|
+
```
|
|
182
|
+
|
|
183
|
+
Review the generated guide before committing. The guide is meant to save time,
|
|
184
|
+
not replace your own final check.
|
|
185
|
+
|
|
186
|
+
## Progress Messages
|
|
187
|
+
|
|
188
|
+
Commands print progress messages so long-running AI calls do not look frozen:
|
|
189
|
+
|
|
190
|
+
```text
|
|
191
|
+
[ 0.0s] Reading file: app/(dashboard)/bookings/page.tsx
|
|
192
|
+
[ 0.0s] Preparing documentation with provider: opencode
|
|
193
|
+
[ 0.0s] Waiting for AI response. This can take a moment...
|
|
194
|
+
[ 5.0s] OpenCode is reading the file and prompt...
|
|
195
|
+
[ 10.0s] OpenCode is drafting the guide...
|
|
196
|
+
```
|
|
197
|
+
|
|
198
|
+
Hide progress messages with:
|
|
199
|
+
|
|
200
|
+
```powershell
|
|
201
|
+
docs-for-me file README.md --quiet
|
|
202
|
+
```
|
|
203
|
+
|
|
204
|
+
## Privacy
|
|
205
|
+
|
|
206
|
+
`--ai none` runs locally and does not call an AI provider.
|
|
207
|
+
|
|
208
|
+
`--ai opencode` sends the relevant file contents or Git diff to OpenCode and to
|
|
209
|
+
whatever model/provider OpenCode is configured to use. Do not use AI mode on
|
|
210
|
+
private or sensitive code unless you are comfortable with that provider handling
|
|
211
|
+
the content.
|
|
212
|
+
|
|
213
|
+
## Current Provider Support
|
|
214
|
+
|
|
215
|
+
Today:
|
|
216
|
+
|
|
217
|
+
- `none`
|
|
218
|
+
- `opencode`
|
|
219
|
+
|
|
220
|
+
The code is provider-based, so more providers can be added later.
|
|
221
|
+
|
|
222
|
+
## Project Status
|
|
223
|
+
|
|
224
|
+
`docs-for-me` is early-stage. It is published on npm for Windows x64 first.
|
|
225
|
+
|
|
226
|
+
Good next steps:
|
|
227
|
+
|
|
228
|
+
- add config file support
|
|
229
|
+
- add more AI providers
|
|
230
|
+
- add macOS and Linux npm builds
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "docs-for-me",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.2",
|
|
4
4
|
"description": "Create programmer-friendly docs for files, folders, and Git changes.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "John Manuel A. Cuerdo",
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
"url": "https://github.com/manwelAC/docs-for-me/issues"
|
|
14
14
|
},
|
|
15
15
|
"bin": {
|
|
16
|
-
"docs-for-me": "./bin/docs-for-me
|
|
16
|
+
"docs-for-me": "./bin/docs-for-me"
|
|
17
17
|
},
|
|
18
18
|
"files": [
|
|
19
19
|
"bin/",
|
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
"scripts": {
|
|
25
25
|
"build:exe:win": "powershell -ExecutionPolicy Bypass -File scripts/build-windows-exe.ps1",
|
|
26
26
|
"pack:npm": "npm pack",
|
|
27
|
-
"test:npm-local": "node bin/docs-for-me
|
|
27
|
+
"test:npm-local": "node bin/docs-for-me --help"
|
|
28
28
|
},
|
|
29
29
|
"keywords": [
|
|
30
30
|
"documentation",
|
|
Binary file
|
|
File without changes
|