@pasosdejesus/m 0.36.0 → 0.36.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 +14 -10
- package/dist/CHANGELOG.md +39 -1
- package/dist/compose/vendor.d.ts +39 -14
- package/dist/compose/vendor.d.ts.map +1 -1
- package/dist/compose/vendor.js +128 -25
- package/dist/compose/vendor.js.map +1 -1
- package/dist/tasks/self-update.js +1 -1
- package/man/man1/m.1 +1 -1
- package/package.json +1 -1
- package/src/shadcn_components/README.md +3 -2
- package/src/tasks/README.md +8 -5
- package/src/test-utils/README.md +1 -1
package/README.md
CHANGED
|
@@ -24,31 +24,35 @@ npx m --help
|
|
|
24
24
|
|
|
25
25
|
`@pasosdejesus/mpdj` is an optional plugin that adds the Pasos de Jesús
|
|
26
26
|
extension (Christian alignment commands `ai:*`, requirements `req:*`,
|
|
27
|
-
credentials). The `usdt` payment engine lives in `@pasosdejesus/usdt
|
|
27
|
+
credentials). The `usdt` payment engine lives in `@pasosdejesus/usdt`; `msip`
|
|
28
|
+
(base model) and `wallet` (user wallet) are **private engines** consumed with
|
|
29
|
+
`eng:sync --vendor` (see [Engines](../../doc/engines.md)).
|
|
28
30
|
|
|
29
31
|
## What it gives you
|
|
30
32
|
|
|
31
33
|
| Area | Commands |
|
|
32
34
|
|------|----------|
|
|
33
|
-
| Scaffolding | `m:create`, `m:update` |
|
|
35
|
+
| Scaffolding | `m:create`, `m:update`, `m:check`, `m:self-update`, `m:man` |
|
|
34
36
|
| Database (PostgreSQL + Kysely) | `db:create`, `db:migrate`, `db:rollback`, `db:dump`, `db:restore`, `db:structure:dump/load`, `db:console`, `db:test`, `db:seed` |
|
|
35
37
|
| Wallet (replaces `cast` on OpenBSD) | `eng:opwallet:generate`, `eng:opwallet:import`, `eng:opwallet:list`, `eng:opwallet:balance`, `eng:opwallet:send`, `eng:opwallet:approve`, `eng:opwallet:call`, `eng:opwallet:sign`, `eng:opwallet:broadcast`, `eng:opwallet:keccak`, `eng:opwallet:derive` — keys in `~/.m/wallets/` with `chmod 600` |
|
|
36
38
|
| Contracts | `contract:test` (EVM via `@pasosdejesus/edr`, no native binaries), `contract:checkdeploy` (deployment addresses and their use) and `contract:compile` (solc/solc-js, no Hardhat) |
|
|
37
39
|
| AI tooling | `ai:context`, `ai:readfile`, `ai:writefile`, `ai:edit`, `ai:grep`, `ai:glob` |
|
|
38
40
|
| Requirements | `req:list`, `req:show`, `req:cross`, `req:compare`, `req:sync-from-repo`, `req:sync-to-repo`, `req:list-repo`, `req:create`, `req:close` |
|
|
39
|
-
| Engines | `m:create engine`, `eng:list`, `eng:sync`, `eng:verify`, `eng:check`, `eng:setup`, `eng:wba:setup`, `eng:credentials:setup`, `eng:msip:setup`, `eng:msip:seed` |
|
|
40
|
-
| Environment | `env:diff` |
|
|
41
|
+
| Engines | `m:create engine`, `eng:list`, `eng:sync`, `eng:verify`, `eng:check`, `eng:setup`, `eng:seed`, `eng:wba:setup`, `eng:credentials:setup`, `eng:msip:setup`, `eng:msip:seed` |
|
|
42
|
+
| Environment | `env:diff`, `env:check` |
|
|
41
43
|
|
|
42
|
-
Subpath exports for programmatic use: `@pasosdejesus/m
|
|
43
|
-
|
|
44
|
-
|
|
44
|
+
Subpath exports for programmatic use: `@pasosdejesus/m/*` (`i18n`, `wba`,
|
|
45
|
+
`wba/routes`, `debug`, `test-utils`, `blockchain/deployments`, `e2e`,
|
|
46
|
+
`engine`, `plugin`, `m`, `wallet`, `wallet/storage`, `wallet/next` and
|
|
47
|
+
`shadcn-components/ui/*`).
|
|
45
48
|
|
|
46
49
|
## Documentation
|
|
47
50
|
|
|
48
51
|
- Repository: <https://gitlab.com/pasosdeJesus/m>
|
|
49
|
-
-
|
|
50
|
-
(full command and export reference),
|
|
51
|
-
|
|
52
|
+
- [ARCHITECTURE.md](../../ARCHITECTURE.md) (design decisions and platform
|
|
53
|
+
constraints), [API.md](../../API.md) (full command and export reference),
|
|
54
|
+
[CONTRIBUTING.md](../../CONTRIBUTING.md) (workflow and tests) and
|
|
55
|
+
[doc/](../../doc/README.md) (feature guides) live in the repository.
|
|
52
56
|
- Changes: `CHANGELOG.md` in the repository, also shipped as
|
|
53
57
|
`dist/CHANGELOG.md` in this package.
|
|
54
58
|
|
package/dist/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,36 @@ All notable changes to `@pasosdejesus/m` are documented in this file.
|
|
|
4
4
|
|
|
5
5
|
## [Unreleased]
|
|
6
6
|
|
|
7
|
+
### Fixed — vendored copies are self-consistent after `eng:sync --vendor` (**`m@0.36.2`**)
|
|
8
|
+
|
|
9
|
+
- `vendor()` now regenerates the derived facts on the copy after writing its `package.json` and
|
|
10
|
+
`tsconfig.json`, so `m-engine.generated.ts` carries `name: generated-<motor>` and the vendored
|
|
11
|
+
version immediately. Consumers no longer need an extra `eng:sync packages/generated/<motor>`
|
|
12
|
+
step, and `eng:verify` no longer reports `GENERATED_STALE` after a re-vendor. `pnpm install`
|
|
13
|
+
(refreshes the workspace link) and compiling the copy are still required.
|
|
14
|
+
|
|
15
|
+
### Fixed — `eng:sync --vendor` output is consumer-ready and content-hashed (**`m@0.36.1`**)
|
|
16
|
+
|
|
17
|
+
- The vendored copy now emits `workspace:*` for sibling engines, rewrites their
|
|
18
|
+
`m-engine.json` package names to `generated-<alias>`, and uses `catalog:` for dependencies the
|
|
19
|
+
consumer already catalogs (`@pasosdejesus/m`, `viem`, …). Consumers no longer need to edit
|
|
20
|
+
`packages/generated/<motor>` after re-vendoring.
|
|
21
|
+
- `PROVENANCE.json` now hashes the whole vendored payload (`sha256`, covering `src/`, `db/`,
|
|
22
|
+
`m-engine.json` and `m-engine.generated.ts`) and keeps the schema hash in `schemaSha256`;
|
|
23
|
+
`eng:check` reports source drift when only a component changes.
|
|
24
|
+
|
|
25
|
+
### Documentation — index, consumer guide and motor workflow
|
|
26
|
+
|
|
27
|
+
- Added [doc/README.md](doc/README.md) as the canonical documentation index,
|
|
28
|
+
[doc/ubuntu-compat.md](doc/ubuntu-compat.md), [REQ/README.md](REQ/README.md) and
|
|
29
|
+
[packages/wallet/README.md](packages/wallet/README.md).
|
|
30
|
+
- Documented the private-motor workflow (bump, `eng:sync`, tag `<motor>-vX.Y.Z`, no npm
|
|
31
|
+
publish) in `doc/engines.md`, `doc/version-bump.md`, `AGENTS.md` and
|
|
32
|
+
`packages/mpdj/SKILL.md`, including the post-vendor steps (vendor regenerates the facts;
|
|
33
|
+
`pnpm install` and compile) and the bare-name trap; synchronized package lists, test
|
|
34
|
+
commands, legacy paths and counts, and replaced stale `apps/nextjs`/`apps/hardhat` paths
|
|
35
|
+
in current guides.
|
|
36
|
+
|
|
7
37
|
### Added — `m:self-update` (**`m@0.36.0`**)
|
|
8
38
|
|
|
9
39
|
- Explicit command to install or refresh a user copy of the CLI in `M_DIR` (`~/.m-cli`): it installs
|
|
@@ -11,7 +41,8 @@ All notable changes to `@pasosdejesus/m` are documented in this file.
|
|
|
11
41
|
ready), always with `--ignore-scripts`; `--check` only asks npm, `--dry-run` prints the command,
|
|
12
42
|
`M_VERSION` pins the version.
|
|
13
43
|
- It never runs at startup and never replaces the packaged `m`: the adJ port installs
|
|
14
|
-
`/usr/local/bin/m` as a symlink to `dist/m.js`, with no wrapper or `m-cli`
|
|
44
|
+
`/usr/local/bin/m` as a symlink to `dist/m.js`, with no wrapper or `m-cli`
|
|
45
|
+
([adJ/REQ/18](https://gitlab.com/pasosdeJesus/adJ/-/work_items/18)).
|
|
15
46
|
|
|
16
47
|
### Added — `contract:compile` compiles without Hardhat (**`contract-test@0.2.0`**)
|
|
17
48
|
|
|
@@ -67,6 +98,13 @@ All notable changes to `@pasosdejesus/m` are documented in this file.
|
|
|
67
98
|
wrapper is never called with a literal (or the directory does not exist), it reports nothing rather
|
|
68
99
|
than guessing. Two tests cover both cases.
|
|
69
100
|
|
|
101
|
+
### Fixed — wallet panel tabs wrap instead of scrolling (**`wallet@0.1.1`**)
|
|
102
|
+
|
|
103
|
+
- The tab bar now grows when its labels need a second row (`h-auto min-h-10`), so
|
|
104
|
+
"Coleccionables" and the other tabs stay inside the tab bar instead of overlapping the
|
|
105
|
+
content below on narrow screens. The panel also keeps a margin from the viewport edges
|
|
106
|
+
on mobile and hides horizontal overflow.
|
|
107
|
+
|
|
70
108
|
## [0.35.0] - 2026-10-20
|
|
71
109
|
|
|
72
110
|
### Changed — generated projects use `contract:test` and `contract:checkdeploy`
|
package/dist/compose/vendor.d.ts
CHANGED
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Vendorización "etapa 0" (https://gitlab.com/pasosdeJesus/m/-/work_items/39 D17): copia trazable de un motor dentro del
|
|
3
3
|
* consumidor (`packages/generated/<motor>`), con **procedencia** (motor, versión,
|
|
4
|
-
* origen
|
|
5
|
-
* cambio del motor = **regenerar**
|
|
4
|
+
* origen, `sha256` del contenido y `schemaSha256` del esquema) para poder medir
|
|
5
|
+
* **drift** contra el original. Adoptar un cambio del motor = **regenerar**
|
|
6
|
+
* (`eng:sync --vendor`), no fusionar a mano. La copia queda autoconsistente:
|
|
7
|
+
* `vendor` regenera sus hechos con el nombre vendorizado (`generated-<motor>`).
|
|
6
8
|
*
|
|
7
9
|
* "Porque ¿quién de vosotros, queriendo edificar una torre, no se sienta primero y calcula los gastos…?" (Lucas 14:28)
|
|
8
10
|
*/
|
|
@@ -12,7 +14,12 @@ export interface Provenance {
|
|
|
12
14
|
version: string;
|
|
13
15
|
/** Ruta local del motor (`kind: 'local'`), o `<url>#<ref>` cuando viene de git. */
|
|
14
16
|
source: string;
|
|
17
|
+
/** Hash del contenido vendorizado (`src`, `db`, intención y hechos). */
|
|
15
18
|
sha256: string;
|
|
19
|
+
/** `payload` cuando `sha256` cubre todo el contenido; ausente en copias antiguas. */
|
|
20
|
+
hash?: 'payload';
|
|
21
|
+
/** Hash del esquema de referencia (`db/structure.sql`), independiente de `src/`. */
|
|
22
|
+
schemaSha256?: string;
|
|
16
23
|
/** De dónde se tomó el motor. Por defecto `local`. */
|
|
17
24
|
kind?: 'local' | 'git';
|
|
18
25
|
/** URL del repositorio cuando `kind: 'git'`. */
|
|
@@ -30,6 +37,14 @@ export interface GitOrigin {
|
|
|
30
37
|
}
|
|
31
38
|
/** `sha256` del esquema de referencia del motor (`db/structure.sql`), o `null`. */
|
|
32
39
|
export declare function structureSha(dir: string): string | null;
|
|
40
|
+
/**
|
|
41
|
+
* `sha256` del contenido que se vendoriza (`src`, `db`, intención y hechos, sin
|
|
42
|
+
* pruebas). Incluye la ruta relativa y el contenido en orden estable, para que
|
|
43
|
+
* cualquier cambio de fuente cambie el hash.
|
|
44
|
+
*/
|
|
45
|
+
export declare function payloadSha(dir: string): string;
|
|
46
|
+
/** Catálogo del workspace pnpm más cercano a `start` (o `{}` si no hay). */
|
|
47
|
+
export declare function findWorkspaceCatalog(start: string): Record<string, string>;
|
|
33
48
|
/**
|
|
34
49
|
* `tsconfig.json` de la copia vendorizada: proyecto **autónomo** (no hereda de `m`),
|
|
35
50
|
* de modo que cada copia se compile por separado (`tsc -b`) y no pese en el
|
|
@@ -42,14 +57,17 @@ export declare function vendoredTsconfig(): string;
|
|
|
42
57
|
* La copia debe **nacer consumible** (auditoría de learn.tg, 2026-10-14):
|
|
43
58
|
* - **Preserva los `exports` reales del motor** (p. ej. `./next` → `dist/components/index.js`),
|
|
44
59
|
* no un `./*` genérico que rompe los subpaths.
|
|
45
|
-
* - **Puentea los motores de los que depende** por **nombre** (`generated-<alias>`): sus `import`
|
|
46
|
-
* reescriben en la copia (ver `rewriteEngineImports`
|
|
47
|
-
*
|
|
48
|
-
* copia al layout
|
|
49
|
-
*
|
|
50
|
-
*
|
|
60
|
+
* - **Puentea los motores de los que depende** por **nombre** (`generated-<alias>`): sus `import` y
|
|
61
|
+
* la intención (`m-engine.json`) se reescriben en la copia (ver `rewriteEngineImports` y
|
|
62
|
+
* `rewriteEngineIntention`) y se declaran como dependencia `workspace:*` (el consumidor añade
|
|
63
|
+
* `packages/generated/*` a su workspace). **Sin rutas `file:../…`**: atarían la copia al layout
|
|
64
|
+
* de una máquina.
|
|
65
|
+
* - Usa `catalog:` para las dependencias que el workspace del consumidor ya cataloga, de modo que
|
|
66
|
+
* la copia comparta la versión única del consumidor (`@pasosdejesus/m`, `viem`, …).
|
|
67
|
+
* - No emite rangos `workspace:` salvo `workspace:*` en los motores hermanos; los `peerDependencies`
|
|
68
|
+
* van como peers (opcionales) **y** como `devDependencies` para que la copia **compile**.
|
|
51
69
|
*/
|
|
52
|
-
export declare function vendoredPackageJson(motorDir: string, pkg: PackageJson | null): string;
|
|
70
|
+
export declare function vendoredPackageJson(motorDir: string, pkg: PackageJson | null, catalog?: Record<string, string>): string;
|
|
53
71
|
/**
|
|
54
72
|
* Motores de los que depende `motorDir`, según su intención: `Map<nombre-de-paquete, alias>`.
|
|
55
73
|
* `engines.<alias>.package` da el nombre real; si falta, se asume `@pasosdejesus/<alias>`.
|
|
@@ -67,6 +85,12 @@ export declare function enginePackages(motorDir: string): Map<string, string>;
|
|
|
67
85
|
* que sí es publicable).
|
|
68
86
|
*/
|
|
69
87
|
export declare function rewriteEngineImports(destDir: string, engines: Map<string, string>): void;
|
|
88
|
+
/**
|
|
89
|
+
* Reescribe la intención (`m-engine.json`) de la copia para que sus motores
|
|
90
|
+
* dependientes apunten al nombre puente (`generated-<alias>`) y no al paquete
|
|
91
|
+
* privado original. Sin esto, `eng:verify` no encuentra el motor hermano.
|
|
92
|
+
*/
|
|
93
|
+
export declare function rewriteEngineIntention(destDir: string, engines: Map<string, string>): void;
|
|
70
94
|
/**
|
|
71
95
|
* Motor original con el que medir el drift de una copia vendorizada: el `--from`
|
|
72
96
|
* (la carpeta del motor, o un checkout donde vive en `packages/<motor>`), y si no
|
|
@@ -80,8 +104,8 @@ export declare function readProvenance(outDir: string): Provenance | null;
|
|
|
80
104
|
/** Quita una copia vendorizada. Devuelve `true` si existía. */
|
|
81
105
|
export declare function unvendor(outDir: string): boolean;
|
|
82
106
|
export type DriftCode = 'ok' | 'drift' | 'absent';
|
|
83
|
-
/** Qué cambió respecto de la procedencia:
|
|
84
|
-
export type DriftReason = 'schema' | 'version';
|
|
107
|
+
/** Qué cambió respecto de la procedencia: esquema, versión o contenido (`src/`). */
|
|
108
|
+
export type DriftReason = 'schema' | 'version' | 'source';
|
|
85
109
|
export interface DriftFinding {
|
|
86
110
|
code: DriftCode;
|
|
87
111
|
message: string;
|
|
@@ -89,9 +113,10 @@ export interface DriftFinding {
|
|
|
89
113
|
}
|
|
90
114
|
/**
|
|
91
115
|
* Mide el drift de una copia vendorizada contra el motor original: primero el
|
|
92
|
-
* esquema (`
|
|
93
|
-
* ([REQ/40](https://gitlab.com/pasosdeJesus/m/-/work_items/40) D5)
|
|
94
|
-
*
|
|
116
|
+
* esquema (`schemaSha256` de `db/structure.sql`), después la **versión** del motor
|
|
117
|
+
* ([REQ/40](https://gitlab.com/pasosdeJesus/m/-/work_items/40) D5) y, en copias nuevas,
|
|
118
|
+
* el contenido (`sha256` de `src`, `db`, intención y hechos). Así también se detecta
|
|
119
|
+
* un cambio de fuente sin cambio de versión.
|
|
95
120
|
*/
|
|
96
121
|
export declare function drift(outDir: string, originalDir: string): DriftFinding;
|
|
97
122
|
//# sourceMappingURL=vendor.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"vendor.d.ts","sourceRoot":"","sources":["../../src/compose/vendor.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"vendor.d.ts","sourceRoot":"","sources":["../../src/compose/vendor.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAOH,OAAO,EAAkC,KAAK,WAAW,EAAE,MAAM,eAAe,CAAA;AAMhF,MAAM,WAAW,UAAU;IACzB,KAAK,EAAE,MAAM,CAAA;IACb,OAAO,EAAE,MAAM,CAAA;IACf,mFAAmF;IACnF,MAAM,EAAE,MAAM,CAAA;IACd,wEAAwE;IACxE,MAAM,EAAE,MAAM,CAAA;IACd,qFAAqF;IACrF,IAAI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CAAC,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,GAAG,IAAI,CAiB1F;AAED;;;;GAIG;AACH,wBAAgB,aAAa,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,EAAE,SAAS,EAAE,MAAM,EAAE,gBAAgB,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAS9G;AAED,mFAAmF;AACnF,wBAAgB,MAAM,CAAC,QAAQ,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,SAAS,CAAC,EAAE,SAAS,GAAG,UAAU,CAqC1F;AAED,6DAA6D;AAC7D,wBAAgB,cAAc,CAAC,MAAM,EAAE,MAAM,GAAG,UAAU,GAAG,IAAI,CAQhE;AAED,+DAA+D;AAC/D,wBAAgB,QAAQ,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAIhD;AAED,MAAM,MAAM,SAAS,GAAG,IAAI,GAAG,OAAO,GAAG,QAAQ,CAAA;AAEjD,oFAAoF;AACpF,MAAM,MAAM,WAAW,GAAG,QAAQ,GAAG,SAAS,GAAG,QAAQ,CAAA;AAEzD,MAAM,WAAW,YAAY;IAC3B,IAAI,EAAE,SAAS,CAAA;IACf,OAAO,EAAE,MAAM,CAAA;IACf,MAAM,CAAC,EAAE,WAAW,CAAA;CACrB;AAED;;;;;;GAMG;AACH,wBAAgB,KAAK,CAAC,MAAM,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,GAAG,YAAY,CA8BvE"}
|
package/dist/compose/vendor.js
CHANGED
|
@@ -1,15 +1,19 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Vendorización "etapa 0" (https://gitlab.com/pasosdeJesus/m/-/work_items/39 D17): copia trazable de un motor dentro del
|
|
3
3
|
* consumidor (`packages/generated/<motor>`), con **procedencia** (motor, versión,
|
|
4
|
-
* origen
|
|
5
|
-
* cambio del motor = **regenerar**
|
|
4
|
+
* origen, `sha256` del contenido y `schemaSha256` del esquema) para poder medir
|
|
5
|
+
* **drift** contra el original. Adoptar un cambio del motor = **regenerar**
|
|
6
|
+
* (`eng:sync --vendor`), no fusionar a mano. La copia queda autoconsistente:
|
|
7
|
+
* `vendor` regenera sus hechos con el nombre vendorizado (`generated-<motor>`).
|
|
6
8
|
*
|
|
7
9
|
* "Porque ¿quién de vosotros, queriendo edificar una torre, no se sienta primero y calcula los gastos…?" (Lucas 14:28)
|
|
8
10
|
*/
|
|
9
|
-
import { cpSync, existsSync, mkdirSync, readdirSync, readFileSync, rmSync, writeFileSync } from 'node:fs';
|
|
11
|
+
import { cpSync, existsSync, mkdirSync, readdirSync, readFileSync, rmSync, statSync, writeFileSync } from 'node:fs';
|
|
10
12
|
import { createHash } from 'node:crypto';
|
|
11
|
-
import { basename, join } from 'node:path';
|
|
13
|
+
import { basename, dirname, join } from 'node:path';
|
|
14
|
+
import { readWorkspaceYaml } from '../util/pnpm-workspace.js';
|
|
12
15
|
import { readIntention, readPackageJson } from './discover.js';
|
|
16
|
+
import { sync } from './sync.js';
|
|
13
17
|
/** Archivos/entradas que se copian del motor a la copia vendorizada. */
|
|
14
18
|
const VENDORED = ['src', 'db', 'm-engine.json', 'm-engine.generated.ts'];
|
|
15
19
|
/** `sha256` del esquema de referencia del motor (`db/structure.sql`), o `null`. */
|
|
@@ -19,6 +23,55 @@ export function structureSha(dir) {
|
|
|
19
23
|
return null;
|
|
20
24
|
return createHash('sha256').update(readFileSync(file)).digest('hex');
|
|
21
25
|
}
|
|
26
|
+
/**
|
|
27
|
+
* `sha256` del contenido que se vendoriza (`src`, `db`, intención y hechos, sin
|
|
28
|
+
* pruebas). Incluye la ruta relativa y el contenido en orden estable, para que
|
|
29
|
+
* cualquier cambio de fuente cambie el hash.
|
|
30
|
+
*/
|
|
31
|
+
export function payloadSha(dir) {
|
|
32
|
+
const files = [];
|
|
33
|
+
const walk = (abs, rel) => {
|
|
34
|
+
for (const entry of readdirSync(abs, { withFileTypes: true })) {
|
|
35
|
+
const childAbs = join(abs, entry.name);
|
|
36
|
+
const childRel = `${rel}/${entry.name}`;
|
|
37
|
+
if (entry.isDirectory())
|
|
38
|
+
walk(childAbs, childRel);
|
|
39
|
+
else if (entry.isFile() && !/\.test\.tsx?$/.test(entry.name))
|
|
40
|
+
files.push(childRel);
|
|
41
|
+
}
|
|
42
|
+
};
|
|
43
|
+
for (const entry of VENDORED) {
|
|
44
|
+
const abs = join(dir, entry);
|
|
45
|
+
if (!existsSync(abs))
|
|
46
|
+
continue;
|
|
47
|
+
if (statSync(abs).isDirectory())
|
|
48
|
+
walk(abs, entry);
|
|
49
|
+
else if (!/\.test\.tsx?$/.test(entry))
|
|
50
|
+
files.push(entry);
|
|
51
|
+
}
|
|
52
|
+
files.sort();
|
|
53
|
+
const hash = createHash('sha256');
|
|
54
|
+
for (const rel of files) {
|
|
55
|
+
hash.update(rel);
|
|
56
|
+
hash.update('\0');
|
|
57
|
+
hash.update(readFileSync(join(dir, rel)));
|
|
58
|
+
hash.update('\0');
|
|
59
|
+
}
|
|
60
|
+
return hash.digest('hex');
|
|
61
|
+
}
|
|
62
|
+
/** Catálogo del workspace pnpm más cercano a `start` (o `{}` si no hay). */
|
|
63
|
+
export function findWorkspaceCatalog(start) {
|
|
64
|
+
let dir = start;
|
|
65
|
+
while (true) {
|
|
66
|
+
const config = readWorkspaceYaml(join(dir, 'pnpm-workspace.yaml'));
|
|
67
|
+
if (config)
|
|
68
|
+
return config.catalog;
|
|
69
|
+
const parent = dirname(dir);
|
|
70
|
+
if (parent === dir)
|
|
71
|
+
return {};
|
|
72
|
+
dir = parent;
|
|
73
|
+
}
|
|
74
|
+
}
|
|
22
75
|
/**
|
|
23
76
|
* `tsconfig.json` de la copia vendorizada: proyecto **autónomo** (no hereda de `m`),
|
|
24
77
|
* de modo que cada copia se compile por separado (`tsc -b`) y no pese en el
|
|
@@ -51,14 +104,17 @@ export function vendoredTsconfig() {
|
|
|
51
104
|
* La copia debe **nacer consumible** (auditoría de learn.tg, 2026-10-14):
|
|
52
105
|
* - **Preserva los `exports` reales del motor** (p. ej. `./next` → `dist/components/index.js`),
|
|
53
106
|
* no un `./*` genérico que rompe los subpaths.
|
|
54
|
-
* - **Puentea los motores de los que depende** por **nombre** (`generated-<alias>`): sus `import`
|
|
55
|
-
* reescriben en la copia (ver `rewriteEngineImports`
|
|
56
|
-
*
|
|
57
|
-
* copia al layout
|
|
58
|
-
*
|
|
59
|
-
*
|
|
107
|
+
* - **Puentea los motores de los que depende** por **nombre** (`generated-<alias>`): sus `import` y
|
|
108
|
+
* la intención (`m-engine.json`) se reescriben en la copia (ver `rewriteEngineImports` y
|
|
109
|
+
* `rewriteEngineIntention`) y se declaran como dependencia `workspace:*` (el consumidor añade
|
|
110
|
+
* `packages/generated/*` a su workspace). **Sin rutas `file:../…`**: atarían la copia al layout
|
|
111
|
+
* de una máquina.
|
|
112
|
+
* - Usa `catalog:` para las dependencias que el workspace del consumidor ya cataloga, de modo que
|
|
113
|
+
* la copia comparta la versión única del consumidor (`@pasosdejesus/m`, `viem`, …).
|
|
114
|
+
* - No emite rangos `workspace:` salvo `workspace:*` en los motores hermanos; los `peerDependencies`
|
|
115
|
+
* van como peers (opcionales) **y** como `devDependencies` para que la copia **compile**.
|
|
60
116
|
*/
|
|
61
|
-
export function vendoredPackageJson(motorDir, pkg) {
|
|
117
|
+
export function vendoredPackageJson(motorDir, pkg, catalog = {}) {
|
|
62
118
|
const name = `generated-${basename(motorDir)}`;
|
|
63
119
|
const version = pkg?.version ?? '0.0.0';
|
|
64
120
|
const engines = enginePackages(motorDir);
|
|
@@ -66,7 +122,9 @@ export function vendoredPackageJson(motorDir, pkg) {
|
|
|
66
122
|
for (const [dep, range] of Object.entries(pkg?.dependencies ?? {})) {
|
|
67
123
|
const sibling = engines.get(dep);
|
|
68
124
|
if (sibling)
|
|
69
|
-
dependencies[`generated-${sibling}`] = '
|
|
125
|
+
dependencies[`generated-${sibling}`] = 'workspace:*';
|
|
126
|
+
else if (catalog[dep])
|
|
127
|
+
dependencies[dep] = 'catalog:';
|
|
70
128
|
else
|
|
71
129
|
dependencies[dep] = range.startsWith('workspace:') ? '*' : range;
|
|
72
130
|
}
|
|
@@ -155,6 +213,32 @@ export function rewriteEngineImports(destDir, engines) {
|
|
|
155
213
|
};
|
|
156
214
|
walk(destDir);
|
|
157
215
|
}
|
|
216
|
+
/**
|
|
217
|
+
* Reescribe la intención (`m-engine.json`) de la copia para que sus motores
|
|
218
|
+
* dependientes apunten al nombre puente (`generated-<alias>`) y no al paquete
|
|
219
|
+
* privado original. Sin esto, `eng:verify` no encuentra el motor hermano.
|
|
220
|
+
*/
|
|
221
|
+
export function rewriteEngineIntention(destDir, engines) {
|
|
222
|
+
if (engines.size === 0)
|
|
223
|
+
return;
|
|
224
|
+
const file = join(destDir, 'm-engine.json');
|
|
225
|
+
if (!existsSync(file))
|
|
226
|
+
return;
|
|
227
|
+
const intention = JSON.parse(readFileSync(file, 'utf-8'));
|
|
228
|
+
if (!intention.engines)
|
|
229
|
+
return;
|
|
230
|
+
let changed = false;
|
|
231
|
+
for (const [alias, ref] of Object.entries(intention.engines)) {
|
|
232
|
+
const original = ref.package ?? `@pasosdejesus/${alias}`;
|
|
233
|
+
const sibling = engines.get(original);
|
|
234
|
+
if (!sibling)
|
|
235
|
+
continue;
|
|
236
|
+
ref.package = `generated-${sibling}`;
|
|
237
|
+
changed = true;
|
|
238
|
+
}
|
|
239
|
+
if (changed)
|
|
240
|
+
writeFileSync(file, `${JSON.stringify(intention, null, 2)}\n`);
|
|
241
|
+
}
|
|
158
242
|
/**
|
|
159
243
|
* Motor original con el que medir el drift de una copia vendorizada: el `--from`
|
|
160
244
|
* (la carpeta del motor, o un checkout donde vive en `packages/<motor>`), y si no
|
|
@@ -186,15 +270,23 @@ export function vendor(motorDir, outDir, gitOrigin) {
|
|
|
186
270
|
cpSync(from, join(outDir, entry), { recursive: true, filter: keep });
|
|
187
271
|
}
|
|
188
272
|
// Puente por nombre: la copia importa `generated-<alias>`, no `@pasosdejesus/<alias>` (private).
|
|
189
|
-
|
|
273
|
+
const engines = enginePackages(motorDir);
|
|
274
|
+
rewriteEngineImports(join(outDir, 'src'), engines);
|
|
275
|
+
rewriteEngineIntention(outDir, engines);
|
|
190
276
|
// Paquete propio + tsconfig autónomo: cada copia se compila por separado (`tsc -b`).
|
|
191
|
-
writeFileSync(join(outDir, 'package.json'), vendoredPackageJson(motorDir, pkg));
|
|
277
|
+
writeFileSync(join(outDir, 'package.json'), vendoredPackageJson(motorDir, pkg, findWorkspaceCatalog(outDir)));
|
|
192
278
|
writeFileSync(join(outDir, 'tsconfig.json'), vendoredTsconfig());
|
|
279
|
+
// Los hechos derivados deben llevar el nombre del paquete vendorizado
|
|
280
|
+
// (`generated-<motor>`, no el upstream): regenéralos sobre la copia.
|
|
281
|
+
sync(outDir);
|
|
282
|
+
const schemaSha = structureSha(motorDir);
|
|
193
283
|
const provenance = {
|
|
194
284
|
motor: pkg?.name ?? basename(motorDir),
|
|
195
285
|
version: pkg?.version ?? '0.0.0',
|
|
196
286
|
source: gitOrigin ? `${gitOrigin.url}#${gitOrigin.ref}` : motorDir,
|
|
197
|
-
sha256:
|
|
287
|
+
sha256: payloadSha(motorDir),
|
|
288
|
+
hash: 'payload',
|
|
289
|
+
...(schemaSha ? { schemaSha256: schemaSha } : {}),
|
|
198
290
|
...(gitOrigin
|
|
199
291
|
? { kind: 'git', origin: gitOrigin.url, ref: gitOrigin.ref, ...(gitOrigin.path ? { path: gitOrigin.path } : {}) }
|
|
200
292
|
: {}),
|
|
@@ -223,21 +315,25 @@ export function unvendor(outDir) {
|
|
|
223
315
|
}
|
|
224
316
|
/**
|
|
225
317
|
* Mide el drift de una copia vendorizada contra el motor original: primero el
|
|
226
|
-
* esquema (`
|
|
227
|
-
* ([REQ/40](https://gitlab.com/pasosdeJesus/m/-/work_items/40) D5)
|
|
228
|
-
*
|
|
318
|
+
* esquema (`schemaSha256` de `db/structure.sql`), después la **versión** del motor
|
|
319
|
+
* ([REQ/40](https://gitlab.com/pasosdeJesus/m/-/work_items/40) D5) y, en copias nuevas,
|
|
320
|
+
* el contenido (`sha256` de `src`, `db`, intención y hechos). Así también se detecta
|
|
321
|
+
* un cambio de fuente sin cambio de versión.
|
|
229
322
|
*/
|
|
230
323
|
export function drift(outDir, originalDir) {
|
|
231
324
|
const provenance = readProvenance(outDir);
|
|
232
325
|
if (!provenance)
|
|
233
326
|
return { code: 'absent', message: `sin procedencia en ${outDir}` };
|
|
234
|
-
const
|
|
235
|
-
if (
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
327
|
+
const currentSchema = structureSha(originalDir);
|
|
328
|
+
if (currentSchema !== null) {
|
|
329
|
+
const recordedSchema = provenance.schemaSha256 ?? provenance.sha256;
|
|
330
|
+
if (recordedSchema !== currentSchema) {
|
|
331
|
+
return {
|
|
332
|
+
code: 'drift',
|
|
333
|
+
reason: 'schema',
|
|
334
|
+
message: `${provenance.motor} v${provenance.version} desactualizado (esquema); corre \`eng:sync --vendor\``,
|
|
335
|
+
};
|
|
336
|
+
}
|
|
241
337
|
}
|
|
242
338
|
const currentVersion = readPackageJson(originalDir)?.version ?? '0.0.0';
|
|
243
339
|
if (provenance.version !== currentVersion) {
|
|
@@ -247,6 +343,13 @@ export function drift(outDir, originalDir) {
|
|
|
247
343
|
message: `${provenance.motor} v${provenance.version} → v${currentVersion} (versión); corre \`eng:sync --vendor\``,
|
|
248
344
|
};
|
|
249
345
|
}
|
|
346
|
+
if (provenance.hash === 'payload' && provenance.sha256 !== payloadSha(originalDir)) {
|
|
347
|
+
return {
|
|
348
|
+
code: 'drift',
|
|
349
|
+
reason: 'source',
|
|
350
|
+
message: `${provenance.motor} v${provenance.version} desactualizado (contenido); corre \`eng:sync --vendor\``,
|
|
351
|
+
};
|
|
352
|
+
}
|
|
250
353
|
return { code: 'ok', message: `${provenance.motor} v${provenance.version} al día` };
|
|
251
354
|
}
|
|
252
355
|
//# sourceMappingURL=vendor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AU,CAAC,MAAM,KAAK,UAAU,CAAC,WAAW,CAAC,EAAE,CAAC;QACnF,OAAO;YACL,IAAI,EAAE,OAAO;YACb,MAAM,EAAE,QAAQ;YAChB,OAAO,EAAE,GAAG,UAAU,CAAC,KAAK,KAAK,UAAU,CAAC,OAAO,0DAA0D;SAC9G,CAAA;IACH,CAAC;IACD,OAAO,EAAE,IAAI,EAAE,IAAI,EAAE,OAAO,EAAE,GAAG,UAAU,CAAC,KAAK,KAAK,UAAU,CAAC,OAAO,SAAS,EAAE,CAAA;AACrF,CAAC"}
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
* it installs with npm into a temporary directory and swaps it atomically,
|
|
8
8
|
* without running lifecycle scripts.
|
|
9
9
|
*
|
|
10
|
-
* https://gitlab.com/pasosdeJesus/
|
|
10
|
+
* https://gitlab.com/pasosdeJesus/adJ/-/work_items/18
|
|
11
11
|
*/
|
|
12
12
|
import * as fs from 'fs';
|
|
13
13
|
import * as os from 'os';
|
package/man/man1/m.1
CHANGED
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
> *"Everything should be done in a fitting and orderly way"* (1 Corinthians 14:40)
|
|
4
4
|
|
|
5
|
-
Collection of
|
|
5
|
+
Collection of 30 [shadcn/ui](https://ui.shadcn.com/) components (plus the `use-toast` hook) packaged in `@pasosdejesus/m` to share across the Pasos de Jesús ecosystem (learn.tg, sivel.xyz, and projects generated with `m:create`).
|
|
6
6
|
|
|
7
7
|
## Installation
|
|
8
8
|
|
|
@@ -66,6 +66,7 @@ cn('px-4 py-2', 'bg-red-500', false && 'hidden')
|
|
|
66
66
|
| Checkbox | `@pasosdejesus/m/shadcn-components/ui/checkbox` |
|
|
67
67
|
| Dialog | `@pasosdejesus/m/shadcn-components/ui/dialog` |
|
|
68
68
|
| DropdownMenu | `@pasosdejesus/m/shadcn-components/ui/dropdown-menu` |
|
|
69
|
+
| Form | `@pasosdejesus/m/shadcn-components/ui/form` |
|
|
69
70
|
| Input | `@pasosdejesus/m/shadcn-components/ui/input` |
|
|
70
71
|
| Label | `@pasosdejesus/m/shadcn-components/ui/label` |
|
|
71
72
|
| Menubar | `@pasosdejesus/m/shadcn-components/ui/menubar` |
|
|
@@ -113,7 +114,7 @@ Then change the import in your code from `@pasosdejesus/m/...` to `@/components/
|
|
|
113
114
|
|
|
114
115
|
## Tailwind CSS
|
|
115
116
|
|
|
116
|
-
Components use Tailwind classes. Your project needs Tailwind configured with the standard `globals.css` file that includes the `@tailwind base/components/utilities` directives. Projects generated with `m
|
|
117
|
+
Components use Tailwind classes. Your project needs Tailwind configured with the standard `globals.css` file that includes the `@tailwind base/components/utilities` directives. Projects generated with `m:create` already come with this setup.
|
|
117
118
|
|
|
118
119
|
## Tests
|
|
119
120
|
|
package/src/tasks/README.md
CHANGED
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
Each file in this directory exports a `runXxx()` function registered in `../m.ts`.
|
|
4
4
|
|
|
5
5
|
> **Qué va en `m` vs `mpdj`:** `m` contiene las órdenes genéricas (db, wallet,
|
|
6
|
-
> engine, req, ai:context/readfile/writefile/grep/glob/edit, m:create/update,
|
|
7
|
-
> env:diff, test:e2e). `mpdj` contiene la extensión Pasos de Jesús
|
|
6
|
+
> engine, req, ai:context/readfile/writefile/grep/glob/edit, m:create/update/check/man/self-update,
|
|
7
|
+
> env:diff/check, test:e2e y warmup). `mpdj` contiene la extensión Pasos de Jesús
|
|
8
8
|
> (`ai:framework`, `ai:verify`, `ai:principles`, `ai:skill`, `ai:adJ`,
|
|
9
9
|
> `eng:credentials:*`). Ver `packages/mpdj/src/tasks/`.
|
|
10
10
|
|
|
@@ -25,8 +25,10 @@ Each file in this directory exports a `runXxx()` function registered in `../m.ts
|
|
|
25
25
|
| `create.ts` | `m:create` | Scaffolds new projects from `templates/` via direct recursive copy (replaced Plop.js) |
|
|
26
26
|
| `db.ts` | `db:create`, `db:drop`, `db:super:createuser`, `db:structure:dump`, `db:structure:load`, `db:migrate`, `db:rollback`, `db:mig:make`, `db:seed`, `db:console`, `db:test`, `db:dump`, `db:restore` | PostgreSQL database lifecycle, migration management, schema verification, and backup/restore |
|
|
27
27
|
| `e2e.ts` | `test:e2e` | E2E tests (Puppeteer specs, axios smoke) |
|
|
28
|
+
| `e2e-summary.ts` | `test:e2e:summary` | Compares per-spec results across E2E logs |
|
|
29
|
+
| `warmup.ts` | `warmup` | Warms up a site (compile sequentially, verify in parallel) |
|
|
28
30
|
| `edit.ts` | `ai:edit` | Parses and applies DeepSeek diff format from clipboard |
|
|
29
|
-
| `engine.ts` | `eng:list`, `eng:sync`, `eng:verify`, `eng:check`, `eng:remove`, `eng:
|
|
31
|
+
| `engine.ts` | `eng:list`, `eng:sync`, `eng:verify`, `eng:check`, `eng:remove`, `eng:setup`, `eng:seed`, `eng:msip:setup`, `eng:wba:setup` | Engine discovery, generated facts, drift, self-containment and migration/seed generation |
|
|
30
32
|
| `env-diff.ts` | `env:diff` | Compares two `.env` files (default: `../.env.example` vs `../.env`), reports differences |
|
|
31
33
|
| `env-check.ts` | `env:check` | Warns about environment variables renamed in the ecosystem (REQ/51), informative only (exit 0) |
|
|
32
34
|
| `fuzzy.ts` | *(internal)* | Fuzzy string matching helpers for `ai:edit` |
|
|
@@ -34,6 +36,7 @@ Each file in this directory exports a `runXxx()` function registered in `../m.ts
|
|
|
34
36
|
| `grep.ts` | `ai:grep` | Text search in files |
|
|
35
37
|
| `readfile.ts` | `ai:readfile` | Reads files with offset/limit support |
|
|
36
38
|
| `req.ts` | `req:list`, `req:show`, `req:cross`, `req:compare`, `req:sync-from-repo`, `req:sync-to-repo`, `req:list-repo`, `req:create`, `req:close` | Requirements management from REQ/ with GitLab/GitHub sync and cross-project detection |
|
|
39
|
+
| `self-update.ts` | `m:self-update` | Installs/refreshes a user copy of the CLI in `~/.m-cli` |
|
|
37
40
|
| `update.ts` | `m:update` | Synchronizes project files with template improvements |
|
|
38
41
|
| `util.ts` | *(internal)* | Shared task helpers |
|
|
39
42
|
| `wallet.ts` | `eng:opwallet:generate`, `eng:opwallet:approve`, `eng:opwallet:list`, `eng:opwallet:import`, `eng:opwallet:send`, `eng:opwallet:balance`, `eng:opwallet:sign`, `eng:opwallet:broadcast`, `eng:opwallet:call`, `eng:opwallet:derive`, `eng:opwallet:keccak` | Wallet management: generate, approve ERC20, send tokens, sign/broadcast (airgapped), contract reads (cast replacement) |
|
|
@@ -44,7 +47,7 @@ Each file in this directory exports a `runXxx()` function registered in `../m.ts
|
|
|
44
47
|
| Paquete | File | Commands |
|
|
45
48
|
|---------|------|----------|
|
|
46
49
|
| `@pasosdejesus/mpdj` | `ai.ts`, `ai-verify-core.ts`, `principles.ts`, `skill.ts`, `adJ.ts` | `ai:framework`, `ai:verify`, `ai:verify:answer`, `ai:principles`, `ai:skill`, `ai:adJ` |
|
|
47
|
-
| `@pasosdejesus/mpdj` | `credentials.ts` | `eng:credentials:list-types`, `eng:credentials:mint`, `eng:credentials:register-type`, `eng:credentials:recompose-image`, `eng:credentials:set-max-supply`, `eng:credentials:set-site-uri`, `eng:credentials:sync-cache`, `eng:credentials:revoke-credential`, `eng:credentials:grant-minter`, `eng:credentials:revoke-minter` |
|
|
50
|
+
| `@pasosdejesus/mpdj` | `credentials.ts` | `eng:credentials:list-types`, `eng:credentials:mint`, `eng:credentials:register-type`, `eng:credentials:recompose-image`, `eng:credentials:set-max-supply`, `eng:credentials:set-site-uri`, `eng:credentials:sync-cache`, `eng:credentials:revoke-credential`, `eng:credentials:grant-minter`, `eng:credentials:revoke-minter`, `eng:credentials:setup` |
|
|
48
51
|
| `@pasosdejesus/contract-test` | `runner.ts`, `hre-mock.ts` | `contract:test` (EDR fallback for OpenBSD) |
|
|
49
52
|
|
|
50
53
|
## Architecture
|
|
@@ -71,7 +74,7 @@ All commands follow the same pattern:
|
|
|
71
74
|
| `eng:` | Engine — crea tablas vía migraciones | [OK] | `eng:credentials:setup`, `eng:wba:setup` |
|
|
72
75
|
| `contract:` | Herramienta de desarrollo | [FAIL] | `contract:test` |
|
|
73
76
|
| `db:` | Base de datos | [FAIL] | `db:migrate`, `db:create` |
|
|
74
|
-
| `
|
|
77
|
+
| `eng:opwallet:` | Billetera del operador | [FAIL] | `eng:opwallet:generate`, `eng:opwallet:send` |
|
|
75
78
|
| `ai:` | Herramientas para agentes | [FAIL] | `ai:context`, `ai:grep` |
|
|
76
79
|
| `m:` | Scaffolding | [FAIL] | `m:create`, `m:update` |
|
|
77
80
|
| `req:` | Requerimientos | [FAIL] | `req:list`, `req:sync` |
|
package/src/test-utils/README.md
CHANGED
|
@@ -137,7 +137,7 @@ test-utils/
|
|
|
137
137
|
|
|
138
138
|
> **mpdj test-utils**: Mocks para los módulos blockchain de `@pasosdejesus/mpdj`
|
|
139
139
|
> (credenciales, deployments, ecosystem-addresses, slearn-info) están en
|
|
140
|
-
> `@pasosdejesus/mpdj/test-utils`. Ver [`packages/mpdj/src/test-utils/README.md`](
|
|
140
|
+
> `@pasosdejesus/mpdj/test-utils`. Ver [`packages/mpdj/src/test-utils/README.md`](../../../mpdj/src/test-utils/README.md).
|
|
141
141
|
|
|
142
142
|
## Available Modules
|
|
143
143
|
|