appydave-tools 0.75.0 → 0.76.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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +25 -0
- data/CLAUDE.md +5 -26
- data/bin/dam +2 -4
- data/bin/gpt_context.rb +65 -22
- data/docs/backlog.md +1 -1
- data/docs/code-quality/README.md +15 -16
- data/docs/planning/AGENTS.md +245 -0
- data/docs/planning/BACKLOG.md +189 -0
- data/docs/planning/bugfix-and-security/AGENTS.md +324 -0
- data/docs/planning/bugfix-and-security/IMPLEMENTATION_PLAN.md +26 -0
- data/docs/planning/fr2-gpt-context-help/AGENTS.md +256 -0
- data/docs/planning/fr2-gpt-context-help/IMPLEMENTATION_PLAN.md +24 -0
- data/docs/planning/fr2-gpt-context-help/assessment.md +70 -0
- data/docs/planning/next-round-brief.md +39 -0
- data/lib/appydave/tools/dam/s3_operations.rb +2 -10
- data/lib/appydave/tools/dam/s3_scanner.rb +1 -2
- data/lib/appydave/tools/dam/share_operations.rb +2 -10
- data/lib/appydave/tools/dam/sync_from_ssd.rb +9 -6
- data/lib/appydave/tools/gpt_context/file_collector.rb +13 -20
- data/lib/appydave/tools/version.rb +1 -1
- data/package.json +1 -1
- metadata +10 -2
|
@@ -0,0 +1,256 @@
|
|
|
1
|
+
# AGENTS.md — fr2-gpt-context-help
|
|
2
|
+
|
|
3
|
+
> Operational knowledge for this campaign's background agents.
|
|
4
|
+
> Inherited from docs/planning/AGENTS.md (2026-03-19). Campaign-specific additions below.
|
|
5
|
+
> Self-contained — you receive only this file + your work unit prompt.
|
|
6
|
+
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
## Project Overview
|
|
10
|
+
|
|
11
|
+
**What:** Ruby gem providing CLI productivity tools for AppyDave's YouTube content creation workflow.
|
|
12
|
+
**Stack:** Ruby 3.4.2, Bundler 2.6.2, RSpec, RuboCop, semantic-release CI/CD.
|
|
13
|
+
**This campaign:** FR-2 — enhance `bin/gpt_context.rb` OptionParser with structured help system. One file. No lib/ changes.
|
|
14
|
+
**Commits:** Always use `kfeat`/`kfix` — never `git commit`.
|
|
15
|
+
|
|
16
|
+
---
|
|
17
|
+
|
|
18
|
+
## Build & Run Commands
|
|
19
|
+
|
|
20
|
+
```bash
|
|
21
|
+
# Initialize rbenv (required if rbenv not in PATH)
|
|
22
|
+
eval "$(rbenv init -)"
|
|
23
|
+
|
|
24
|
+
# Run tests
|
|
25
|
+
bundle exec rspec # All tests
|
|
26
|
+
bundle exec rspec spec/appydave/tools/gpt_context/ # GPT context specs only
|
|
27
|
+
RUBYOPT="-W0" bundle exec rspec # Suppress Ruby 3.4 platform warnings
|
|
28
|
+
|
|
29
|
+
# Lint
|
|
30
|
+
bundle exec rubocop --format clang # Standard lint check (matches CI)
|
|
31
|
+
|
|
32
|
+
# Manual verification
|
|
33
|
+
bin/gpt_context.rb --help # Should show structured help
|
|
34
|
+
bin/gpt_context.rb --version # Should show version
|
|
35
|
+
bin/gpt_context.rb -v # Short version flag
|
|
36
|
+
bin/gpt_context.rb --help | grep -E "^(SYNOPSIS|DESCRIPTION|OPTIONS|OUTPUT FORMATS|EXAMPLES)"
|
|
37
|
+
|
|
38
|
+
# Commit (never use git commit directly)
|
|
39
|
+
kfeat "add AI-friendly help system to GPT Context" # Use this exact message
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
**Baseline (2026-03-19):** 748 examples, 0 failures, 84.88% line coverage (7680/9048)
|
|
43
|
+
|
|
44
|
+
---
|
|
45
|
+
|
|
46
|
+
## Directory Structure
|
|
47
|
+
|
|
48
|
+
```
|
|
49
|
+
bin/gpt_context.rb ← THE ONLY FILE TO CHANGE
|
|
50
|
+
lib/appydave/tools/gpt_context/
|
|
51
|
+
file_collector.rb Read-only reference (DO NOT MODIFY)
|
|
52
|
+
options.rb Read-only reference (DO NOT MODIFY)
|
|
53
|
+
output_handler.rb Read-only reference (DO NOT MODIFY)
|
|
54
|
+
lib/appydave/tools/version.rb Read-only — VERSION constant lives here
|
|
55
|
+
spec/appydave/tools/gpt_context/
|
|
56
|
+
cli_spec.rb ← CREATE THIS (new file)
|
|
57
|
+
file_collector_spec.rb Existing — do not modify
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
---
|
|
61
|
+
|
|
62
|
+
## Success Criteria
|
|
63
|
+
|
|
64
|
+
Every work unit must satisfy ALL before marking `[x]`:
|
|
65
|
+
|
|
66
|
+
- [ ] `bundle exec rspec` — 748+ examples, 0 failures (new specs add to this count)
|
|
67
|
+
- [ ] `bundle exec rubocop --format clang` — 0 offenses
|
|
68
|
+
- [ ] Line coverage stays ≥ 84.88%
|
|
69
|
+
- [ ] `bin/gpt_context.rb --help` output includes SYNOPSIS, DESCRIPTION, OPTIONS, OUTPUT FORMATS, EXAMPLES sections
|
|
70
|
+
- [ ] `bin/gpt_context.rb --version` outputs `gpt_context version X.Y.Z`
|
|
71
|
+
- [ ] `spec/appydave/tools/gpt_context/cli_spec.rb` exists with ≥ 3 passing tests
|
|
72
|
+
- [ ] Banner no longer says `gather_content.rb` — it says `gpt_context`
|
|
73
|
+
- [ ] `# frozen_string_literal: true` at top of new spec file
|
|
74
|
+
|
|
75
|
+
---
|
|
76
|
+
|
|
77
|
+
## Work Unit Spec
|
|
78
|
+
|
|
79
|
+
### fr2-gpt-context-help — Implement AI-friendly help system
|
|
80
|
+
|
|
81
|
+
**File to modify:** `bin/gpt_context.rb`
|
|
82
|
+
|
|
83
|
+
**What to do:**
|
|
84
|
+
|
|
85
|
+
1. Replace the `opts.banner` line with a heredoc banner containing Synopsis and Description sections
|
|
86
|
+
2. Add `opts.separator` calls for OUTPUT FORMATS and EXAMPLES sections after the options
|
|
87
|
+
3. Add `--version` / `-v` flag before the `--help` flag
|
|
88
|
+
4. Enhance each option's description to include defaults and examples (multi-line array format)
|
|
89
|
+
5. Fix the banner script name: currently `gather_content.rb` → should be `gpt_context`
|
|
90
|
+
|
|
91
|
+
**Full implementation pattern** (from spec, Option A):
|
|
92
|
+
|
|
93
|
+
```ruby
|
|
94
|
+
OptionParser.new do |opts|
|
|
95
|
+
opts.banner = <<~BANNER
|
|
96
|
+
GPT Context Gatherer - Collect project files for AI context
|
|
97
|
+
|
|
98
|
+
SYNOPSIS
|
|
99
|
+
gpt_context [options]
|
|
100
|
+
|
|
101
|
+
DESCRIPTION
|
|
102
|
+
Collects and packages codebase files for AI assistant context.
|
|
103
|
+
Outputs to clipboard (default), file, or stdout.
|
|
104
|
+
|
|
105
|
+
BANNER
|
|
106
|
+
|
|
107
|
+
opts.separator "OPTIONS"
|
|
108
|
+
opts.separator ""
|
|
109
|
+
|
|
110
|
+
opts.on('-i', '--include PATTERN',
|
|
111
|
+
'Glob pattern for files to include (repeatable)',
|
|
112
|
+
'Example: -i "lib/**/*.rb" -i "bin/**/*.rb"') do |pattern|
|
|
113
|
+
options.include_patterns << pattern
|
|
114
|
+
end
|
|
115
|
+
|
|
116
|
+
opts.on('-e', '--exclude PATTERN',
|
|
117
|
+
'Glob pattern for files to exclude (repeatable)',
|
|
118
|
+
'Example: -e "spec/**/*" -e "node_modules/**/*"') do |pattern|
|
|
119
|
+
options.exclude_patterns << pattern
|
|
120
|
+
end
|
|
121
|
+
|
|
122
|
+
opts.on('-f', '--format FORMATS',
|
|
123
|
+
'Output format(s): tree, content, json, aider, files',
|
|
124
|
+
'Comma-separated. Default: content',
|
|
125
|
+
'Example: -f tree,content') do |format|
|
|
126
|
+
options.format = format
|
|
127
|
+
end
|
|
128
|
+
|
|
129
|
+
opts.on('-o', '--output TARGET',
|
|
130
|
+
'Output target: clipboard, filename, or stdout',
|
|
131
|
+
'Default: clipboard. Repeatable for multiple targets.') do |target|
|
|
132
|
+
options.output_target << target
|
|
133
|
+
end
|
|
134
|
+
|
|
135
|
+
opts.on('-d', '--debug [MODE]', 'Enable debug mode [none, info, params, debug]',
|
|
136
|
+
'none', 'info', 'params', 'debug') do |debug|
|
|
137
|
+
options.debug = debug || 'info'
|
|
138
|
+
end
|
|
139
|
+
|
|
140
|
+
opts.on('-l', '--line-limit N', Integer,
|
|
141
|
+
'Limit lines per file (default: unlimited)') do |n|
|
|
142
|
+
options.line_limit = n
|
|
143
|
+
end
|
|
144
|
+
|
|
145
|
+
opts.on('-b', '--base-dir DIRECTORY',
|
|
146
|
+
'Set the base directory to gather files from') do |directory|
|
|
147
|
+
options.working_directory = directory
|
|
148
|
+
end
|
|
149
|
+
|
|
150
|
+
opts.on('-p', '--prompt TEXT',
|
|
151
|
+
'Prompt text for aider format output') do |message|
|
|
152
|
+
options.prompt = message
|
|
153
|
+
end
|
|
154
|
+
|
|
155
|
+
opts.separator ""
|
|
156
|
+
opts.separator "OUTPUT FORMATS"
|
|
157
|
+
opts.separator " tree - Directory tree structure"
|
|
158
|
+
opts.separator " content - File contents with headers (default)"
|
|
159
|
+
opts.separator " json - Structured JSON output"
|
|
160
|
+
opts.separator " aider - Aider CLI command format (requires -p)"
|
|
161
|
+
opts.separator " files - File paths only"
|
|
162
|
+
opts.separator ""
|
|
163
|
+
opts.separator "EXAMPLES"
|
|
164
|
+
opts.separator " # Gather Ruby library code for AI context"
|
|
165
|
+
opts.separator " gpt_context -i 'lib/**/*.rb' -e 'spec/**/*' -d"
|
|
166
|
+
opts.separator ""
|
|
167
|
+
opts.separator " # Project structure overview"
|
|
168
|
+
opts.separator " gpt_context -i '**/*' -f tree -e 'node_modules/**/*'"
|
|
169
|
+
opts.separator ""
|
|
170
|
+
opts.separator " # Save to file with tree and content"
|
|
171
|
+
opts.separator " gpt_context -i 'src/**/*.ts' -f tree,content -o context.txt"
|
|
172
|
+
opts.separator ""
|
|
173
|
+
opts.separator " # Generate aider command"
|
|
174
|
+
opts.separator " gpt_context -i 'lib/**/*.rb' -f aider -p 'Add logging'"
|
|
175
|
+
opts.separator ""
|
|
176
|
+
|
|
177
|
+
opts.on('-v', '--version', 'Show version') do
|
|
178
|
+
puts "gpt_context version #{Appydave::Tools::VERSION}"
|
|
179
|
+
exit
|
|
180
|
+
end
|
|
181
|
+
|
|
182
|
+
opts.on_tail('-h', '--help', 'Show this help') do
|
|
183
|
+
puts opts
|
|
184
|
+
exit
|
|
185
|
+
end
|
|
186
|
+
end.parse!
|
|
187
|
+
```
|
|
188
|
+
|
|
189
|
+
**New spec file** `spec/appydave/tools/gpt_context/cli_spec.rb`:
|
|
190
|
+
|
|
191
|
+
```ruby
|
|
192
|
+
# frozen_string_literal: true
|
|
193
|
+
|
|
194
|
+
RSpec.describe 'gpt_context CLI help' do
|
|
195
|
+
let(:script) { File.expand_path('../../../../bin/gpt_context.rb', __dir__) }
|
|
196
|
+
|
|
197
|
+
describe '--help' do
|
|
198
|
+
subject(:output) { `ruby #{script} --help 2>&1` }
|
|
199
|
+
|
|
200
|
+
it 'includes SYNOPSIS section' do
|
|
201
|
+
expect(output).to include('SYNOPSIS')
|
|
202
|
+
end
|
|
203
|
+
|
|
204
|
+
it 'includes EXAMPLES section' do
|
|
205
|
+
expect(output).to include('EXAMPLES')
|
|
206
|
+
end
|
|
207
|
+
|
|
208
|
+
it 'includes OUTPUT FORMATS section' do
|
|
209
|
+
expect(output).to include('OUTPUT FORMATS')
|
|
210
|
+
end
|
|
211
|
+
end
|
|
212
|
+
|
|
213
|
+
describe '--version' do
|
|
214
|
+
it 'shows version number' do
|
|
215
|
+
output = `ruby #{script} --version 2>&1`
|
|
216
|
+
expect(output).to match(/gpt_context version \d+\.\d+\.\d+/)
|
|
217
|
+
end
|
|
218
|
+
end
|
|
219
|
+
end
|
|
220
|
+
```
|
|
221
|
+
|
|
222
|
+
---
|
|
223
|
+
|
|
224
|
+
## Anti-Patterns to Avoid
|
|
225
|
+
|
|
226
|
+
- ❌ Do NOT modify any file in `lib/` — this campaign is bin/ only
|
|
227
|
+
- ❌ Do NOT use `opts.on_tail` for `--version` (use `opts.on` so it appears before `--help` in output)
|
|
228
|
+
- ❌ Do NOT leave the banner saying `gather_content.rb`
|
|
229
|
+
- ❌ Do NOT require spec_helper explicitly — it's auto-required via `.rspec` config
|
|
230
|
+
- ❌ Do NOT use `system()` or backticks in specs to call the script with a path that includes spaces
|
|
231
|
+
|
|
232
|
+
---
|
|
233
|
+
|
|
234
|
+
## Quality Gates
|
|
235
|
+
|
|
236
|
+
- **Tests:** `bundle exec rspec` — 748+ examples, 0 failures
|
|
237
|
+
- **Lint:** `bundle exec rubocop --format clang` — 0 offenses
|
|
238
|
+
- **Coverage:** ≥ 84.88% line coverage
|
|
239
|
+
- **Manual:** `bin/gpt_context.rb --help` and `--version` work as expected
|
|
240
|
+
- **Commit format:** `kfeat "add AI-friendly help system to GPT Context"`
|
|
241
|
+
|
|
242
|
+
---
|
|
243
|
+
|
|
244
|
+
## Learnings (inherited)
|
|
245
|
+
|
|
246
|
+
### From Three-Lens Audit (2026-03-19)
|
|
247
|
+
- `file_collector.rb` pre-conditions (B015, B019) already fixed in commit 13d5f87 — do not re-fix
|
|
248
|
+
- BUG-1 already verified fixed — do not re-investigate
|
|
249
|
+
|
|
250
|
+
### From DAM Enhancement Sprint (Jan 2025)
|
|
251
|
+
- `Config.configure` is memoized — idempotent
|
|
252
|
+
- Table format() pattern: always use same format string for headers and data rows
|
|
253
|
+
|
|
254
|
+
### From Jump Location Tool (Dec 2025)
|
|
255
|
+
- Dependency injection for path validators required for CI compatibility
|
|
256
|
+
- Jump Commands layer is undertested — not relevant to this campaign
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
# IMPLEMENTATION_PLAN.md — fr2-gpt-context-help
|
|
2
|
+
|
|
3
|
+
**Goal**: Enhance GPT Context CLI with AI-friendly help system (FR-2)
|
|
4
|
+
**Started**: 2026-03-19
|
|
5
|
+
**Target**: `--help` shows structured sections; `--version` works; specs pass; rubocop clean
|
|
6
|
+
|
|
7
|
+
## Summary
|
|
8
|
+
- Total: 1 | Complete: 1 | In Progress: 0 | Pending: 0 | Failed: 0
|
|
9
|
+
|
|
10
|
+
## Pending
|
|
11
|
+
|
|
12
|
+
## In Progress
|
|
13
|
+
|
|
14
|
+
## Complete
|
|
15
|
+
- [x] fr2-gpt-context-help — Implement AI-friendly help system in bin/gpt_context.rb. 754 examples, 0 failures. v0.76.0 published. Also fixed pre-existing rubocop offenses in bin/dam and split jump_test_helpers (JumpTestLocations → own file).
|
|
16
|
+
|
|
17
|
+
## Failed / Needs Retry
|
|
18
|
+
|
|
19
|
+
## Notes & Decisions
|
|
20
|
+
- Pre-conditions already satisfied: B015 (FileUtils.cd) and B019 (debug puts) fixed in commit 13d5f87
|
|
21
|
+
- Implementation is Option A from spec: enhanced OptionParser only — no changes to lib/
|
|
22
|
+
- Fix banner script name while in there (currently says gather_content.rb, should say gpt_context)
|
|
23
|
+
- New spec file: spec/appydave/tools/gpt_context/cli_spec.rb (3 tests minimum)
|
|
24
|
+
- Commit with: kfeat "add AI-friendly help system to GPT Context"
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
# Assessment: fr2-gpt-context-help
|
|
2
|
+
|
|
3
|
+
**Campaign**: fr2-gpt-context-help
|
|
4
|
+
**Date**: 2026-03-19 → 2026-03-19
|
|
5
|
+
**Results**: 1 complete, 0 failed
|
|
6
|
+
**Version shipped**: v0.76.0
|
|
7
|
+
**Quality audit**: code-quality-audit + test-quality-audit run post-campaign
|
|
8
|
+
|
|
9
|
+
---
|
|
10
|
+
|
|
11
|
+
## Results Summary
|
|
12
|
+
|
|
13
|
+
| Work Unit | Status | Notes |
|
|
14
|
+
|-----------|--------|-------|
|
|
15
|
+
| B002 — FR-2 GPT Context help system | ✅ Complete | 754 examples, 0 failures. Also fixed pre-existing rubocop offenses in bin/dam and split JumpTestLocations into own file. |
|
|
16
|
+
|
|
17
|
+
---
|
|
18
|
+
|
|
19
|
+
## What Worked Well
|
|
20
|
+
|
|
21
|
+
- **Single-file scope held.** `bin/gpt_context.rb` only — no lib/ changes. Agent stayed in bounds.
|
|
22
|
+
- **Side-fixes landed cleanly.** Rubocop offenses in bin/dam (select/reject → partition) and JumpTestLocations split were caught and fixed without scope creep.
|
|
23
|
+
- **Test count and coverage improved.** 748 → 754 examples, 84.88% → 84.92% coverage.
|
|
24
|
+
- **Spec approach was correct.** subprocess integration testing (running the actual script) is the right pattern for CLI help/version tests.
|
|
25
|
+
- **Pre-conditions were pre-cleared.** B015 and B019 fixed in prior commit 13d5f87 meant agent could focus on FR-2 immediately.
|
|
26
|
+
|
|
27
|
+
---
|
|
28
|
+
|
|
29
|
+
## What Didn't Work
|
|
30
|
+
|
|
31
|
+
- **cli_spec.rb is too thin (Grade: C from test audit).** 4 tests only verify help text strings are present. No functional tests: `-i`, `-e`, `-f`, `-o` flags completely untested at CLI level. Creates false sense of security.
|
|
32
|
+
- **format.nil? guard is dead code.** `bin/gpt_context.rb` line 115 checks `options.format.nil?` as part of its "no options provided" guard. But `format` defaults to `'content'` in the Options class — it is never nil. The third AND condition is always false, meaning the guard can only trigger if both include_patterns AND exclude_patterns are empty AND format has somehow been set to nil (impossible via normal usage).
|
|
33
|
+
- **file_collector_spec missing formats.** JSON and aider format output paths in FileCollector have zero specs. Error cases also unprotected.
|
|
34
|
+
|
|
35
|
+
---
|
|
36
|
+
|
|
37
|
+
## Key Learnings — Application
|
|
38
|
+
|
|
39
|
+
- **OptionParser `opts.on_tail` vs `opts.on` matters for ordering.** `--version` must be `opts.on` (not `on_tail`) to appear before `--help` in output. Anti-pattern documented in AGENTS.md.
|
|
40
|
+
- **format.nil? is a dead guard.** When Options class sets a default for `format`, the nil check in bin/gpt_context.rb line 115 is always false. Any "no args provided" guard must check `include_patterns.empty?` and `exclude_patterns.empty?` only.
|
|
41
|
+
- **Subprocess specs work but need functional assertions.** Using `\`ruby #{script} --flag\`` is correct for CLI integration testing, but tests must verify actual output content and exit codes — not just documentation strings.
|
|
42
|
+
|
|
43
|
+
---
|
|
44
|
+
|
|
45
|
+
## Key Learnings — Ralph Loop
|
|
46
|
+
|
|
47
|
+
- **One work unit campaigns are fast.** 1 agent, 1 wave, done. No coordination overhead.
|
|
48
|
+
- **Pre-conditions from prior commits reduce campaign scope.** B015/B019 were in next-round-brief as work units but had already been fixed. Always verify pre-conditions live before writing the plan.
|
|
49
|
+
- **Quality audit caught 3 new backlog items.** B021 (format.nil? dead guard), B022 (cli_spec functional tests), B023 (file_collector JSON/aider/error specs). These were invisible without the audit.
|
|
50
|
+
|
|
51
|
+
---
|
|
52
|
+
|
|
53
|
+
## Suggestions for Next Campaign
|
|
54
|
+
|
|
55
|
+
**Recommended next campaign: `bugfix-and-security` — B016, B017, B021**
|
|
56
|
+
|
|
57
|
+
Priority order:
|
|
58
|
+
1. **B017** — ssl_verify_peer: false (security BLOCKER — remove before adding any S3 features)
|
|
59
|
+
2. **B016** — ManifestGenerator vs SyncFromSsd range string mismatch (data integrity BLOCKER)
|
|
60
|
+
3. **B021** — fix format.nil? dead guard in gpt_context (5-minute fix, prevents silent failure)
|
|
61
|
+
|
|
62
|
+
Then schedule soon after:
|
|
63
|
+
- **B022** — expand cli_spec.rb with functional tests (-i, -e, -f, -o, exit codes)
|
|
64
|
+
- **B023** — file_collector_spec: add JSON, aider, error path coverage
|
|
65
|
+
- **B018** — Jump Commands layer specs (Remove/Add/Update)
|
|
66
|
+
|
|
67
|
+
**AGENTS.md updates needed for next campaign:**
|
|
68
|
+
- Add: "format.nil? in gpt_context is always false — do not use as a no-args guard"
|
|
69
|
+
- Add: "S3Operations ssl_verify_peer must be removed — see B017"
|
|
70
|
+
- Add: "ManifestGenerator and SyncFromSsd produce incompatible range strings — see B016 before touching SSD archive paths"
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
# Next Round Brief
|
|
2
|
+
|
|
3
|
+
**Created:** 2026-03-19
|
|
4
|
+
**Updated:** 2026-03-19 (after fr2-gpt-context-help assessment)
|
|
5
|
+
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
## Recommended Next Campaign: bugfix-and-security
|
|
9
|
+
|
|
10
|
+
### Goal
|
|
11
|
+
|
|
12
|
+
Fix two BLOCKER-level bugs (B016, B017) and one dead-code guard (B021) before building any new S3 or archive features.
|
|
13
|
+
|
|
14
|
+
### Background
|
|
15
|
+
|
|
16
|
+
Quality audit after fr2-gpt-context-help surfaced these as blockers:
|
|
17
|
+
|
|
18
|
+
1. **B017** — `ssl_verify_peer: false` hardcoded unconditionally in `S3Operations` and `ShareOperations`. Removes MITM protection on all S3 operations including credential transmission. Must fix before any S3 feature work.
|
|
19
|
+
2. **B016** — `ManifestGenerator.determine_range` returns `"b50-b99"` format; `SyncFromSsd.determine_range` returns `"60-69"` format. Incompatible SSD path construction means projects can be silently missed during archive/restore. Must fix before any archive feature work.
|
|
20
|
+
3. **B021** — `bin/gpt_context.rb` line 115 guard checks `options.format.nil?` as third AND condition. `format` defaults to `'content'` in Options — never nil. Dead condition; guard can only fire on include/exclude emptiness. 5-minute fix.
|
|
21
|
+
|
|
22
|
+
### Suggested Work Units
|
|
23
|
+
|
|
24
|
+
1. **Fix B017** — Remove `ssl_verify_peer: false` from `S3Operations` and `ShareOperations`. No env flag needed — AWS SDK handles SSL correctly by default.
|
|
25
|
+
2. **Fix B016** — Align range string format between `ManifestGenerator` and `SyncFromSsd`. Read actual SSD folder structure on disk first to determine which format matches reality; update the other to match.
|
|
26
|
+
3. **Fix B021** — Remove `&& options.format.nil?` from guard at `bin/gpt_context.rb:115`. Update or add spec to verify no-args behavior.
|
|
27
|
+
|
|
28
|
+
### Optional (bundle if small)
|
|
29
|
+
|
|
30
|
+
- **B018** — Jump Commands layer specs (Remove/Add/Update) — no code changes, just test coverage
|
|
31
|
+
- **B022** — Expand cli_spec.rb with functional tests for -i, -e, -f, -o flags
|
|
32
|
+
|
|
33
|
+
### Mode Recommendation
|
|
34
|
+
|
|
35
|
+
**Extend** — stack, patterns, and quality gates known. Inherit AGENTS.md.
|
|
36
|
+
|
|
37
|
+
### Pre-Campaign Blockers: None
|
|
38
|
+
|
|
39
|
+
All three fixes are standalone. B016 requires reading SSD disk structure before writing code (per AGENTS.md: read actual files before designing data shapes).
|
|
@@ -100,17 +100,9 @@ module Appydave
|
|
|
100
100
|
end
|
|
101
101
|
|
|
102
102
|
def configure_ssl_options
|
|
103
|
-
|
|
104
|
-
if ENV['AWS_SDK_RUBY_SKIP_SSL_VERIFICATION'] == 'true'
|
|
105
|
-
puts '⚠️ WARNING: SSL verification is disabled (development mode)'
|
|
106
|
-
return { ssl_verify_peer: false }
|
|
107
|
-
end
|
|
103
|
+
return { ssl_verify_peer: false } if ENV['AWS_SDK_RUBY_SKIP_SSL_VERIFICATION'] == 'true'
|
|
108
104
|
|
|
109
|
-
|
|
110
|
-
# This is safe for AWS S3 connections as we're still using HTTPS (encrypted connection)
|
|
111
|
-
{
|
|
112
|
-
ssl_verify_peer: false
|
|
113
|
-
}
|
|
105
|
+
{}
|
|
114
106
|
end
|
|
115
107
|
|
|
116
108
|
public
|
|
@@ -87,17 +87,9 @@ module Appydave
|
|
|
87
87
|
end
|
|
88
88
|
|
|
89
89
|
def configure_ssl_options
|
|
90
|
-
|
|
91
|
-
if ENV['AWS_SDK_RUBY_SKIP_SSL_VERIFICATION'] == 'true'
|
|
92
|
-
puts '⚠️ WARNING: SSL verification is disabled (development mode)'
|
|
93
|
-
return { ssl_verify_peer: false }
|
|
94
|
-
end
|
|
90
|
+
return { ssl_verify_peer: false } if ENV['AWS_SDK_RUBY_SKIP_SSL_VERIFICATION'] == 'true'
|
|
95
91
|
|
|
96
|
-
|
|
97
|
-
# This is safe for AWS S3 connections as we're still using HTTPS (encrypted connection)
|
|
98
|
-
{
|
|
99
|
-
ssl_verify_peer: false
|
|
100
|
-
}
|
|
92
|
+
{}
|
|
101
93
|
end
|
|
102
94
|
|
|
103
95
|
public
|
|
@@ -181,14 +181,17 @@ module Appydave
|
|
|
181
181
|
sync_light_files(ssd_path, local_dir, dry_run: dry_run)
|
|
182
182
|
end
|
|
183
183
|
|
|
184
|
-
# Determine range folder for project (e.g., b65 →
|
|
184
|
+
# Determine range folder for project (e.g., b65 → b50-b99)
|
|
185
185
|
def determine_range(project_id)
|
|
186
|
-
# FliVideo pattern: b40,
|
|
187
|
-
if project_id =~ /^
|
|
188
|
-
|
|
189
|
-
|
|
186
|
+
# FliVideo/Modern pattern: b40, a82, etc.
|
|
187
|
+
if project_id =~ /^([a-z])(\d+)/
|
|
188
|
+
letter = Regexp.last_match(1)
|
|
189
|
+
number = Regexp.last_match(2).to_i
|
|
190
|
+
range_start = (number / 50) * 50
|
|
191
|
+
range_end = range_start + 49
|
|
192
|
+
format("#{letter}%02d-#{letter}%02d", range_start, range_end)
|
|
190
193
|
else
|
|
191
|
-
# Legacy pattern or unknown
|
|
194
|
+
# Legacy pattern or unknown
|
|
192
195
|
'000-099'
|
|
193
196
|
end
|
|
194
197
|
end
|
|
@@ -12,36 +12,29 @@ module Appydave
|
|
|
12
12
|
@exclude_patterns = options.exclude_patterns
|
|
13
13
|
@format = options.format
|
|
14
14
|
@working_directory = File.expand_path(options.working_directory)
|
|
15
|
-
puts @working_directory
|
|
16
15
|
@line_limit = options.line_limit
|
|
17
16
|
end
|
|
18
17
|
|
|
19
18
|
def build
|
|
20
|
-
|
|
19
|
+
return build_formats unless @working_directory && Dir.exist?(@working_directory)
|
|
21
20
|
|
|
22
|
-
|
|
23
|
-
|
|
21
|
+
FileUtils.cd(@working_directory) { build_formats }
|
|
22
|
+
end
|
|
23
|
+
|
|
24
|
+
private
|
|
25
|
+
|
|
26
|
+
def build_formats
|
|
27
|
+
@format.split(',').map do |fmt|
|
|
24
28
|
case fmt
|
|
25
|
-
when 'tree'
|
|
26
|
-
|
|
27
|
-
when '
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
build_json
|
|
31
|
-
when 'aider'
|
|
32
|
-
build_aider
|
|
33
|
-
else
|
|
34
|
-
''
|
|
29
|
+
when 'tree' then build_tree
|
|
30
|
+
when 'content' then build_content
|
|
31
|
+
when 'json' then build_json
|
|
32
|
+
when 'aider' then build_aider
|
|
33
|
+
else ''
|
|
35
34
|
end
|
|
36
35
|
end.join("\n\n")
|
|
37
|
-
|
|
38
|
-
FileUtils.cd(Dir.home) if @working_directory
|
|
39
|
-
|
|
40
|
-
result
|
|
41
36
|
end
|
|
42
37
|
|
|
43
|
-
private
|
|
44
|
-
|
|
45
38
|
def build_content
|
|
46
39
|
concatenated_content = []
|
|
47
40
|
|
data/package.json
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: appydave-tools
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.76.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- David Cruwys
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2026-
|
|
11
|
+
date: 2026-03-19 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: activemodel
|
|
@@ -295,6 +295,14 @@ files:
|
|
|
295
295
|
- docs/guides/tools/video-file-namer.md
|
|
296
296
|
- docs/guides/tools/youtube-automation.md
|
|
297
297
|
- docs/guides/tools/youtube-manager.md
|
|
298
|
+
- docs/planning/AGENTS.md
|
|
299
|
+
- docs/planning/BACKLOG.md
|
|
300
|
+
- docs/planning/bugfix-and-security/AGENTS.md
|
|
301
|
+
- docs/planning/bugfix-and-security/IMPLEMENTATION_PLAN.md
|
|
302
|
+
- docs/planning/fr2-gpt-context-help/AGENTS.md
|
|
303
|
+
- docs/planning/fr2-gpt-context-help/IMPLEMENTATION_PLAN.md
|
|
304
|
+
- docs/planning/fr2-gpt-context-help/assessment.md
|
|
305
|
+
- docs/planning/next-round-brief.md
|
|
298
306
|
- docs/specs/fr-002-gpt-context-help-system.md
|
|
299
307
|
- docs/specs/fr-003-jump-location-tool.md
|
|
300
308
|
- docs/specs/zsh-history-tool.md
|