Docs: flux nou de editare VFP pe text (txt2vcx.ps1) + cale cache corectata
CLAUDE.md: calea cache-ului text e D:\ROA\_vfp_textcache\roagest (nu _textcache_roagest); editarile de cod .vcx/.scx se fac acum direct pe .vc2/.sc2 + write-back cu txt2vcx.ps1 (.mnx/.frx raman read-only, COMUN doar cu -AllowComun). Nota noua docs/flux-editare-vfp-text.md cu fluxul, comenzile si limitele. todo.txt: 2 itemi pending (faza 2 mnx/frx, text-as-source-of-truth in git). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
15
CLAUDE.md
15
CLAUDE.md
@@ -26,17 +26,26 @@ Git rulează în paralel cu SVN-ul legacy, nu îl înlocuiește. SVN rămâne su
|
||||
|
||||
- Repo-ul principal (rădăcina acestui folder) e propriul lui `.git`, cu remote `git@gitea.romfast.ro:romfast/roagest.git`. `.gitignore` exclude `COMUN/` (gestionat separat, vezi mai jos), `.svn/`, artefactele VFP compilate (`*.fxp`, `*.bak`, `*.mpr`, `*.exe`, …) și fișierele Windows uzuale.
|
||||
- `COMUN/` are propriul `.git` separat, cu remote `git@gitea.romfast.ro:romfast/comun.git` — **același repo partajat de toate aplicațiile ROA** (ROAACNPRO, ROAIMOB, etc.). O modificare împinsă acolo afectează toate proiectele. Nu face `push --force` peste `comun.git` fără aprobare explicită — ar șterge istoric comun tuturor proiectelor.
|
||||
- Căutarea în cod VFP binar (`.vcx`/`.scx`) pentru acest proiect folosește `vcx2txt.ps1` parametrizat pentru ROAGEST (vezi secțiunea de mai jos) — cache separat, `_textcache_roagest`, nu-l amesteca cu cache-urile altor proiecte.
|
||||
- Căutarea în cod VFP binar (`.vcx`/`.scx`) pentru acest proiect folosește `vcx2txt.ps1` parametrizat pentru ROAGEST (vezi secțiunea de mai jos) — cache separat, `D:\ROA\_vfp_textcache\roagest`, nu-l amesteca cu cache-urile altor proiecte.
|
||||
|
||||
## Searching code inside `.vcx`/`.scx` (binary) libraries
|
||||
|
||||
Most class/form code lives **inside binaries** (`.vcx`+`.vct`, `.scx`+`.sct`, …), not in `.prg`, so plain grep can't read it cleanly. To search method/procedure bodies, convert the binaries to their TEXT form first and grep the text, using the shared `foxbin2prg` tool already built at `D:\ROA\UTIL\foxbin2prg\FoxBin2Prg.EXE`:
|
||||
|
||||
```powershell
|
||||
& 'D:\ROA\UTIL\foxbin2prg\vcx2txt.ps1' -Project 'D:\ROA\ROAGEST\roagest.pjx' -ProjectRoot 'D:\ROA\ROAGEST' -CacheRoot 'D:\ROA\UTIL\foxbin2prg\_textcache_roagest' -Types vcx,scx,frx,mnx
|
||||
& 'D:\ROA\UTIL\foxbin2prg\vcx2txt.ps1' -Project 'D:\ROA\ROAGEST\roagest.pjx' -ProjectRoot 'D:\ROA\ROAGEST' -CacheRoot 'D:\ROA\_vfp_textcache\roagest' -Types vcx,scx,frx,mnx
|
||||
```
|
||||
|
||||
This reads the file list straight from `roagest.pjx`, so it only converts the `.vcx`/`.scx`/`.frx`/`.mnx` this project actually references — not all of `COMUN\` (most of which is unused by any one app). It's incremental and safe to re-run after IDE edits. Output lands in `_textcache_roagest/` as `.vc2`/`.sc2`/`.fr2`/`.mn2` text mirrors — `Grep` those. The text is **only for reading/search** — make real edits in the VFP IDE, then re-run the script to refresh the cache.
|
||||
This reads the file list straight from `roagest.pjx`, so it only converts the `.vcx`/`.scx`/`.frx`/`.mnx` this project actually references — not all of `COMUN\` (most of which is unused by any one app). It's incremental and safe to re-run after IDE edits. Output lands in `D:\ROA\_vfp_textcache\roagest\` as `.vc2`/`.sc2`/`.fr2`/`.mn2` text mirrors — `Grep` those.
|
||||
|
||||
For `.vcx`/`.scx`, code edits no longer require the VFP IDE — the flow is now:
|
||||
|
||||
1. Refresh the cache (`vcx2txt.ps1` above), especially if a VFP IDE session ran since the last refresh (IDE changes make the cache stale).
|
||||
2. Edit the `.vc2`/`.sc2` text directly (position-sensitive format — don't reflow lines; properties are alphabetized).
|
||||
3. Review the diff on the text file like any other source change.
|
||||
4. Write back with `txt2vcx.ps1` (`D:\ROA\UTIL\foxbin2prg\txt2vcx.ps1 -TextFile <path\to\file.vc2> -ProjectRoot 'D:\ROA\ROAGEST' -CacheRoot 'D:\ROA\_vfp_textcache\roagest'`) — it regenerates and recompiles the binary in a staging folder, fidelity-checks it against the edited text, then copies it into the project only if that check passes.
|
||||
|
||||
`.mnx`/`.frx` stay **read-only** in this flow (menus still need GENMENU in the IDE; reports are too fragile to round-trip) — edit those in the VFP IDE as before. Targets under `COMUN\` need `-AllowComun` plus explicit approval, since a change there affects every ROA app. See `D:\ROA\UTIL\foxbin2prg\CLAUDE.md` for full details and `docs/flux-editare-vfp-text.md` for the ROAGEST-specific notes.
|
||||
|
||||
## The COMUN shared framework
|
||||
|
||||
|
||||
Reference in New Issue
Block a user