aontu 0.64.0 → 0.65.0
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 +2 -2
- package/dist/agentsmd.js +3 -3
- package/dist/agentsmd.js.map +1 -1
- package/dist/aontu.d.ts +1 -1
- package/dist/aontu.js +1 -1
- package/dist/cli.d.ts +15 -2
- package/dist/cli.js +523 -137
- package/dist/cli.js.map +1 -1
- package/dist/compat.d.ts +7 -0
- package/dist/compat.js +113 -0
- package/dist/compat.js.map +1 -0
- package/dist/helpdoc.js +5 -5
- package/dist/helpdoc.js.map +1 -1
- package/dist/hints.js +11 -5
- package/dist/hints.js.map +1 -1
- package/dist/lang.d.ts +1 -0
- package/dist/lang.js +8 -0
- package/dist/lang.js.map +1 -1
- package/dist/lsp.d.ts +1 -1
- package/dist/mod.d.ts +18 -3
- package/dist/mod.js +117 -46
- package/dist/mod.js.map +1 -1
- package/dist/pkg-net.d.ts +227 -0
- package/dist/pkg-net.js +1598 -0
- package/dist/pkg-net.js.map +1 -0
- package/dist/pkg-zip.d.ts +8 -0
- package/dist/pkg-zip.js +196 -0
- package/dist/pkg-zip.js.map +1 -0
- package/dist/pkg.d.ts +159 -0
- package/dist/pkg.js +767 -0
- package/dist/pkg.js.map +1 -0
- package/dist/report-sarif.js +1 -1
- package/dist/report-sarif.js.map +1 -1
- package/dist/subsume.d.ts +3 -1
- package/dist/subsume.js +2 -0
- package/dist/subsume.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +1 -1
- package/skill/SKILL.md +3 -3
- package/skill/error-codes.md +4 -4
- package/skill/examples.md +4 -4
- package/skill/grammar-card.md +1 -1
- package/skill/init/check.sh +2 -2
- package/skill/tasks.md +6 -6
- package/src/agentsmd.ts +3 -3
- package/src/aontu.ts +1 -1
- package/src/cli.ts +610 -150
- package/src/compat.ts +148 -0
- package/src/helpdoc.ts +5 -5
- package/src/hints.ts +11 -7
- package/src/lang.ts +9 -1
- package/src/mod.ts +142 -51
- package/src/pkg-net.ts +1945 -0
- package/src/pkg-zip.ts +228 -0
- package/src/pkg.ts +1018 -0
- package/src/report-sarif.ts +1 -1
- package/src/subsume.ts +2 -2
- package/dist/mod-tool.d.ts +0 -58
- package/dist/mod-tool.js +0 -418
- package/dist/mod-tool.js.map +0 -1
- package/src/mod-tool.ts +0 -578
package/skill/error-codes.md
CHANGED
|
@@ -10,9 +10,9 @@ test suite holds to the engine in both implementations.
|
|
|
10
10
|
| Class | Meaning | What to do |
|
|
11
11
|
|-------|---------|------------|
|
|
12
12
|
| `parse` | the text is not a document | fix the syntax at the site the frame points at |
|
|
13
|
-
| `conflict` | two values cannot both hold | one of them is wrong: `aontu why <path>` names both and where they were written |
|
|
13
|
+
| `conflict` | two values cannot both hold | one of them is wrong: `aontu model why <path>` names both and where they were written |
|
|
14
14
|
| `incomplete` | nothing contradicts, but the value is not concrete | supply what is missing, or accept it with `--partial` |
|
|
15
|
-
| `reference` | a path names nothing | check the spelling; `aontu get $ --keys` lists what is there |
|
|
15
|
+
| `reference` | a path names nothing | check the spelling; `aontu model get $ --keys` lists what is there |
|
|
16
16
|
| `compat` | a change breaks an earlier version | that is `aontu subsume` / `aontu breaking` talking: widen the change or version it |
|
|
17
17
|
| `budget` | evaluation hit a deterministic limit | usually a cycle; simplify, or raise the budget deliberately |
|
|
18
18
|
| `internal` | the engine surprised itself | a bug worth reporting |
|
|
@@ -37,14 +37,14 @@ offending values filled in, and for several codes it names the fix
|
|
|
37
37
|
outright — `lossy_integer_literal` tells you to write the literal as
|
|
38
38
|
`0d…`. It is absent for codes that have no hint text.
|
|
39
39
|
|
|
40
|
-
For a conflict, `aontu why <path> mine.aon` lists every contribution
|
|
40
|
+
For a conflict, `aontu model why <path> mine.aon` lists every contribution
|
|
41
41
|
to that path with its role and source line, which turns "these
|
|
42
42
|
disagree" into "these two lines disagree".
|
|
43
43
|
|
|
44
44
|
Then fix it:
|
|
45
45
|
|
|
46
46
|
```
|
|
47
|
-
aontu set '$.replicas=5' --entry schema.aon --overlay mine.aon --in-place
|
|
47
|
+
aontu model set '$.replicas=5' --entry schema.aon --overlay mine.aon --in-place
|
|
48
48
|
```
|
|
49
49
|
|
|
50
50
|
`--in-place` rewrites the pinned literal **where it was written**, so
|
package/skill/examples.md
CHANGED
|
@@ -59,7 +59,7 @@ services: {
|
|
|
59
59
|
}
|
|
60
60
|
```
|
|
61
61
|
|
|
62
|
-
The `&:` template meets EVERY key. `aontu why $.services.db.replicas`
|
|
62
|
+
The `&:` template meets EVERY key. `aontu model why $.services.db.replicas`
|
|
63
63
|
reports both contributions — the template's `*1|integer` and the
|
|
64
64
|
literal `3` — with the line each was written on.
|
|
65
65
|
|
|
@@ -83,7 +83,7 @@ A port of `0` is now an error with a path, not a runtime surprise.
|
|
|
83
83
|
service: { image: string, replicas: *1 | integer }
|
|
84
84
|
|
|
85
85
|
# prod.aon
|
|
86
|
-
@"base.aon"
|
|
86
|
+
@"./base.aon"
|
|
87
87
|
service: { image: "auth:v2.3", replicas: 5 }
|
|
88
88
|
```
|
|
89
89
|
|
|
@@ -91,9 +91,9 @@ Unification is order-independent: `base & prod` is `prod & base`. To
|
|
|
91
91
|
change a value without editing the file, append to an overlay:
|
|
92
92
|
|
|
93
93
|
```
|
|
94
|
-
aontu set '$.service.replicas=7' --entry prod.aon --overlay local.aon
|
|
94
|
+
aontu model set '$.service.replicas=7' --entry prod.aon --overlay local.aon
|
|
95
95
|
```
|
|
96
96
|
|
|
97
97
|
If the value is PINNED rather than open, that command refuses and
|
|
98
98
|
names the pinning site — which is the honest answer, and where
|
|
99
|
-
`aontu why` takes you next.
|
|
99
|
+
`aontu model why` takes you next.
|
package/skill/grammar-card.md
CHANGED
|
@@ -54,6 +54,6 @@ ranges meet to their overlap.
|
|
|
54
54
|
|
|
55
55
|
## Files
|
|
56
56
|
|
|
57
|
-
`@"other.aon"` includes another document — it unifies in, it does not
|
|
57
|
+
`@"./other.aon"` includes another document — it unifies in, it does not
|
|
58
58
|
concatenate. (A constrained decoder is not given this: generated
|
|
59
59
|
documents describe values, they do not load files.)
|
package/skill/init/check.sh
CHANGED
|
@@ -16,10 +16,10 @@ cd "$(dirname "$0")"
|
|
|
16
16
|
$AONTU vet --strict-coverage model.aon data.aon
|
|
17
17
|
|
|
18
18
|
# 2. What does it say at a path?
|
|
19
|
-
$AONTU get '$.entity.planet.table' data.aon
|
|
19
|
+
$AONTU model get '$.entity.planet.table' data.aon
|
|
20
20
|
|
|
21
21
|
# 3. Why does it say that? Every contribution, with the line it is on.
|
|
22
|
-
$AONTU why '$.entity.planet.table' data.aon
|
|
22
|
+
$AONTU model why '$.entity.planet.table' data.aon
|
|
23
23
|
|
|
24
24
|
# 4. A pin for the truth: it survives reformatting and moves on any
|
|
25
25
|
# change of meaning.
|
package/skill/tasks.md
CHANGED
|
@@ -82,7 +82,7 @@ aontu trim --check model.aon # entries whose removal changes nothing
|
|
|
82
82
|
## Generate code from a model, and hold it
|
|
83
83
|
|
|
84
84
|
```
|
|
85
|
-
aontu get out gen.aon # the component tree: files, and the lines in them
|
|
85
|
+
aontu model get out gen.aon # the component tree: files, and the lines in them
|
|
86
86
|
aontu trace gen.aon # what rule wrote each line
|
|
87
87
|
```
|
|
88
88
|
|
|
@@ -96,10 +96,10 @@ rule behind it.
|
|
|
96
96
|
## Ask what a model says, and why
|
|
97
97
|
|
|
98
98
|
```
|
|
99
|
-
aontu get $.entity.planet.table model.aon
|
|
100
|
-
aontu why $.entity.planet.table model.aon
|
|
101
|
-
aontu get $.entity --keys model.aon
|
|
102
|
-
aontu get $.entity --types model.aon
|
|
99
|
+
aontu model get $.entity.planet.table model.aon
|
|
100
|
+
aontu model why $.entity.planet.table model.aon
|
|
101
|
+
aontu model get $.entity --keys model.aon
|
|
102
|
+
aontu model get $.entity --types model.aon
|
|
103
103
|
```
|
|
104
104
|
|
|
105
105
|
`why` names **every** contribution to a value, with the file and line
|
|
@@ -109,7 +109,7 @@ what you expected, and the second thing to run when `vet` refuses.
|
|
|
109
109
|
## Change a value without editing the file
|
|
110
110
|
|
|
111
111
|
```
|
|
112
|
-
aontu set '$.entity.planet.table=planet_v2' --entry model.aon --overlay local.aon
|
|
112
|
+
aontu model set '$.entity.planet.table=planet_v2' --entry model.aon --overlay local.aon
|
|
113
113
|
```
|
|
114
114
|
|
|
115
115
|
The change is checked before it is written; a change that contradicts
|
package/src/agentsmd.ts
CHANGED
|
@@ -80,16 +80,16 @@ export function agentsMd(
|
|
|
80
80
|
'',
|
|
81
81
|
'```',
|
|
82
82
|
'# what does it say at a path?',
|
|
83
|
-
'aontu get ' + example + ' ' + name,
|
|
83
|
+
'aontu model get ' + example + ' ' + name,
|
|
84
84
|
'',
|
|
85
85
|
'# why does that value hold?',
|
|
86
|
-
'aontu why ' + example + ' ' + name,
|
|
86
|
+
'aontu model why ' + example + ' ' + name,
|
|
87
87
|
'',
|
|
88
88
|
'# does my document satisfy it?',
|
|
89
89
|
'aontu vet ' + name + ' mine.aon',
|
|
90
90
|
'',
|
|
91
91
|
'# change it without editing it',
|
|
92
|
-
'aontu set ' + example + '=<value> --entry ' + name +
|
|
92
|
+
'aontu model set ' + example + '=<value> --entry ' + name +
|
|
93
93
|
' --overlay overlay.aon',
|
|
94
94
|
'',
|
|
95
95
|
'# the language itself, offline: the whole grammar on one page',
|
package/src/aontu.ts
CHANGED