@voxgig/sdkgen 4.21.0 → 4.22.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/bin/voxgig-sdkgen +1 -1
- package/dist/action/action.js +0 -65
- package/dist/action/action.js.map +1 -1
- package/dist/action/check.js +0 -88
- package/dist/action/check.js.map +1 -1
- package/dist/action/dispatch.js +0 -27
- package/dist/action/dispatch.js.map +1 -1
- package/dist/action/doctor.d.ts +1 -0
- package/dist/action/doctor.js +55 -321
- package/dist/action/doctor.js.map +1 -1
- package/dist/action/edition.js +1 -87
- package/dist/action/edition.js.map +1 -1
- package/dist/action/feature.js +0 -48
- package/dist/action/feature.js.map +1 -1
- package/dist/action/kind.js +0 -132
- package/dist/action/kind.js.map +1 -1
- package/dist/action/package.js +0 -221
- package/dist/action/package.js.map +1 -1
- package/dist/action/resolve.js +0 -145
- package/dist/action/resolve.js.map +1 -1
- package/dist/action/target.js +0 -177
- package/dist/action/target.js.map +1 -1
- package/dist/cmp/AgentGuide.js +0 -7
- package/dist/cmp/AgentGuide.js.map +1 -1
- package/dist/cmp/AgentGuideContent.js +0 -24
- package/dist/cmp/AgentGuideContent.js.map +1 -1
- package/dist/cmp/AgentGuideTop.js +0 -7
- package/dist/cmp/AgentGuideTop.js.map +1 -1
- package/dist/cmp/Changelog.js +0 -14
- package/dist/cmp/Changelog.js.map +1 -1
- package/dist/cmp/Deploy.js +1 -31
- package/dist/cmp/Deploy.js.map +1 -1
- package/dist/cmp/Entity.js +0 -4
- package/dist/cmp/Entity.js.map +1 -1
- package/dist/cmp/ExternalTarget.js +0 -36
- package/dist/cmp/ExternalTarget.js.map +1 -1
- package/dist/cmp/Feature.js +0 -14
- package/dist/cmp/Feature.js.map +1 -1
- package/dist/cmp/FeatureDocs.js +0 -25
- package/dist/cmp/FeatureDocs.js.map +1 -1
- package/dist/cmp/PublishWorkflow.js +0 -60
- package/dist/cmp/PublishWorkflow.js.map +1 -1
- package/dist/cmp/ReadmeErrors.js +0 -2
- package/dist/cmp/ReadmeErrors.js.map +1 -1
- package/dist/cmp/ReadmeExplanation.js +0 -5
- package/dist/cmp/ReadmeExplanation.js.map +1 -1
- package/dist/cmp/ReadmeFeatures.js +0 -10
- package/dist/cmp/ReadmeFeatures.js.map +1 -1
- package/dist/cmp/ReadmeRefFeatures.js +0 -19
- package/dist/cmp/ReadmeRefFeatures.js.map +1 -1
- package/dist/cmp/ReadmeStation.js +0 -19
- package/dist/cmp/ReadmeStation.js.map +1 -1
- package/dist/cmp/ReadmeTop.js +0 -80
- package/dist/cmp/ReadmeTop.js.map +1 -1
- package/dist/cmp/ReadmeUnions.js +0 -15
- package/dist/cmp/ReadmeUnions.js.map +1 -1
- package/dist/cmp/Registered.js +0 -30
- package/dist/cmp/Registered.js.map +1 -1
- package/dist/cmp/Security.js +0 -2
- package/dist/cmp/Security.js.map +1 -1
- package/dist/cmp/Test.js +2 -1
- package/dist/cmp/Test.js.map +1 -1
- package/dist/cmp/TestControl.js +0 -25
- package/dist/cmp/TestControl.js.map +1 -1
- package/dist/helpers/applicability.js +0 -60
- package/dist/helpers/applicability.js.map +1 -1
- package/dist/helpers/buildIdNames.js +0 -12
- package/dist/helpers/buildIdNames.js.map +1 -1
- package/dist/helpers/canonSpec.js +0 -114
- package/dist/helpers/canonSpec.js.map +1 -1
- package/dist/helpers/canonType.js +0 -87
- package/dist/helpers/canonType.js.map +1 -1
- package/dist/helpers/collectDeps.js +0 -27
- package/dist/helpers/collectDeps.js.map +1 -1
- package/dist/helpers/definition.js +0 -29
- package/dist/helpers/definition.js.map +1 -1
- package/dist/helpers/dryrun.js +0 -8
- package/dist/helpers/dryrun.js.map +1 -1
- package/dist/helpers/featureSource.js +0 -145
- package/dist/helpers/featureSource.js.map +1 -1
- package/dist/helpers/getMatchEntries.js +0 -4
- package/dist/helpers/getMatchEntries.js.map +1 -1
- package/dist/helpers/junk.js +9 -85
- package/dist/helpers/junk.js.map +1 -1
- package/dist/helpers/manifest.js +0 -138
- package/dist/helpers/manifest.js.map +1 -1
- package/dist/helpers/modelNames.js +0 -78
- package/dist/helpers/modelNames.js.map +1 -1
- package/dist/helpers/modelcheck.js +0 -106
- package/dist/helpers/modelcheck.js.map +1 -1
- package/dist/helpers/naming.d.ts +0 -1
- package/dist/helpers/naming.js +0 -303
- package/dist/helpers/naming.js.map +1 -1
- package/dist/helpers/opExample.js +0 -51
- package/dist/helpers/opExample.js.map +1 -1
- package/dist/helpers/opShape.js +0 -198
- package/dist/helpers/opShape.js.map +1 -1
- package/dist/helpers/optspec.js +0 -77
- package/dist/helpers/optspec.js.map +1 -1
- package/dist/helpers/packageMeta.js +1 -200
- package/dist/helpers/packageMeta.js.map +1 -1
- package/dist/helpers/pointPath.js +0 -55
- package/dist/helpers/pointPath.js.map +1 -1
- package/dist/helpers/resolved.d.ts +6 -0
- package/dist/helpers/resolved.js +49 -0
- package/dist/helpers/resolved.js.map +1 -0
- package/dist/helpers/semver.js +0 -61
- package/dist/helpers/semver.js.map +1 -1
- package/dist/helpers/serverVars.js +0 -44
- package/dist/helpers/serverVars.js.map +1 -1
- package/dist/helpers/shipped.js +0 -14
- package/dist/helpers/shipped.js.map +1 -1
- package/dist/helpers/station.js +0 -32
- package/dist/helpers/station.js.map +1 -1
- package/dist/helpers/stdrep.js +0 -26
- package/dist/helpers/stdrep.js.map +1 -1
- package/dist/helpers/testPolicy.js +0 -4
- package/dist/helpers/testPolicy.js.map +1 -1
- package/dist/sdkgen.d.ts +2 -1
- package/dist/sdkgen.js +13 -242
- package/dist/sdkgen.js.map +1 -1
- package/dist/testkit.js +6 -266
- package/dist/testkit.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/utility.js +0 -243
- package/dist/utility.js.map +1 -1
- package/model/sdkgen.aon +12 -489
- package/package.json +4 -4
- package/project/.sdk/model/feature/audit.aon +0 -7
- package/project/.sdk/model/feature/cache.aon +0 -7
- package/project/.sdk/model/feature/clienttrack.aon +0 -7
- package/project/.sdk/model/feature/cost.aon +0 -13
- package/project/.sdk/model/feature/debug.aon +0 -7
- package/project/.sdk/model/feature/idempotency.aon +0 -7
- package/project/.sdk/model/feature/log.aon +0 -7
- package/project/.sdk/model/feature/metrics.aon +0 -7
- package/project/.sdk/model/feature/netsim.aon +0 -10
- package/project/.sdk/model/feature/paging.aon +0 -7
- package/project/.sdk/model/feature/proxy.aon +0 -7
- package/project/.sdk/model/feature/ratelimit.aon +0 -7
- package/project/.sdk/model/feature/retry.aon +0 -7
- package/project/.sdk/model/feature/secrets.aon +0 -482
- package/project/.sdk/model/feature/streaming.aon +0 -7
- package/project/.sdk/model/feature/telemetry.aon +0 -7
- package/project/.sdk/model/feature/test.aon +1 -8
- package/project/.sdk/model/feature/timeout.aon +0 -7
- package/project/.sdk/model/feature/validate.aon +0 -32
- package/project/.sdk/model/target/c.aon +0 -41
- package/project/.sdk/model/target/clojure.aon +0 -36
- package/project/.sdk/model/target/cpp.aon +0 -42
- package/project/.sdk/model/target/csharp.aon +0 -26
- package/project/.sdk/model/target/elixir.aon +0 -22
- package/project/.sdk/model/target/go-cli.aon +0 -30
- package/project/.sdk/model/target/go-mcp.aon +0 -21
- package/project/.sdk/model/target/go.aon +0 -9
- package/project/.sdk/model/target/java.aon +0 -29
- package/project/.sdk/model/target/js.aon +2 -21
- package/project/.sdk/model/target/kotlin.aon +0 -31
- package/project/.sdk/model/target/lua.aon +0 -32
- package/project/.sdk/model/target/ocaml.aon +0 -64
- package/project/.sdk/model/target/perl.aon +0 -20
- package/project/.sdk/model/target/php.aon +0 -17
- package/project/.sdk/model/target/py-data.aon +0 -33
- package/project/.sdk/model/target/py.aon +0 -17
- package/project/.sdk/model/target/rb.aon +0 -17
- package/project/.sdk/model/target/rust.aon +0 -25
- package/project/.sdk/model/target/scala.aon +0 -74
- package/project/.sdk/model/target/swift.aon +0 -41
- package/project/.sdk/model/target/ts.aon +3 -25
- package/project/.sdk/model/target/zig.aon +0 -50
- package/project/.sdk/src/cmp/c/Config_c.ts +0 -100
- package/project/.sdk/src/cmp/c/EntityTypes_c.ts +0 -36
- package/project/.sdk/src/cmp/c/Main_c.ts +0 -44
- package/project/.sdk/src/cmp/c/Package_c.ts +0 -14
- package/project/.sdk/src/cmp/c/PrepareAuth_c.ts +0 -85
- package/project/.sdk/src/cmp/c/ReadmeExamplesTest_c.ts +0 -20
- package/project/.sdk/src/cmp/c/ReadmeRef_c.ts +2 -5
- package/project/.sdk/src/cmp/c/ReadmeTopQuick_c.ts +0 -2
- package/project/.sdk/src/cmp/c/Schema_c.ts +0 -19
- package/project/.sdk/src/cmp/c/utility_c.ts +0 -47
- package/project/.sdk/src/cmp/clojure/Config_clojure.ts +0 -63
- package/project/.sdk/src/cmp/clojure/Entity_clojure.ts +0 -1
- package/project/.sdk/src/cmp/clojure/Main_clojure.ts +0 -41
- package/project/.sdk/src/cmp/clojure/Package_clojure.ts +0 -20
- package/project/.sdk/src/cmp/clojure/PrepareAuth_clojure.ts +0 -130
- package/project/.sdk/src/cmp/clojure/ReadmeExamplesTest_clojure.ts +0 -16
- package/project/.sdk/src/cmp/clojure/ReadmeRef_clojure.ts +2 -5
- package/project/.sdk/src/cmp/clojure/Schema_clojure.ts +0 -20
- package/project/.sdk/src/cmp/clojure/TestDirect_clojure.ts +0 -6
- package/project/.sdk/src/cmp/clojure/TestEntity_clojure.ts +0 -10
- package/project/.sdk/src/cmp/clojure/Test_clojure.ts +0 -8
- package/project/.sdk/src/cmp/clojure/featureextra_clojure.ts +0 -34
- package/project/.sdk/src/cmp/clojure/utility_clojure.ts +0 -47
- package/project/.sdk/src/cmp/cpp/Config_cpp.ts +0 -109
- package/project/.sdk/src/cmp/cpp/EntityTypes_cpp.ts +0 -36
- package/project/.sdk/src/cmp/cpp/Main_cpp.ts +0 -47
- package/project/.sdk/src/cmp/cpp/Package_cpp.ts +0 -14
- package/project/.sdk/src/cmp/cpp/PrepareAuth_cpp.ts +0 -125
- package/project/.sdk/src/cmp/cpp/ReadmeExamplesTest_cpp.ts +0 -19
- package/project/.sdk/src/cmp/cpp/ReadmeQuick_cpp.ts +0 -7
- package/project/.sdk/src/cmp/cpp/ReadmeRef_cpp.ts +2 -5
- package/project/.sdk/src/cmp/cpp/Schema_cpp.ts +0 -21
- package/project/.sdk/src/cmp/cpp/TestEntity_cpp.ts +0 -3
- package/project/.sdk/src/cmp/cpp/Test_cpp.ts +0 -3
- package/project/.sdk/src/cmp/cpp/utility_cpp.ts +0 -28
- package/project/.sdk/src/cmp/csharp/Config_csharp.ts +0 -79
- package/project/.sdk/src/cmp/csharp/EntityOperation_csharp.ts +0 -3
- package/project/.sdk/src/cmp/csharp/EntityTypes_csharp.ts +0 -50
- package/project/.sdk/src/cmp/csharp/Entity_csharp.ts +0 -1
- package/project/.sdk/src/cmp/csharp/Main_csharp.ts +0 -24
- package/project/.sdk/src/cmp/csharp/Package_csharp.ts +0 -20
- package/project/.sdk/src/cmp/csharp/PrepareAuth_csharp.ts +0 -81
- package/project/.sdk/src/cmp/csharp/ReadmeEntity_csharp.ts +0 -1
- package/project/.sdk/src/cmp/csharp/ReadmeExamplesTest_csharp.ts +0 -23
- package/project/.sdk/src/cmp/csharp/ReadmeRef_csharp.ts +2 -5
- package/project/.sdk/src/cmp/csharp/ReadmeTopQuick_csharp.ts +0 -2
- package/project/.sdk/src/cmp/csharp/Schema_csharp.ts +0 -18
- package/project/.sdk/src/cmp/csharp/TestEntity_csharp.ts +0 -4
- package/project/.sdk/src/cmp/csharp/utility_csharp.ts +0 -72
- package/project/.sdk/src/cmp/elixir/Config_elixir.ts +0 -78
- package/project/.sdk/src/cmp/elixir/EntityTypes_elixir.ts +0 -38
- package/project/.sdk/src/cmp/elixir/Main_elixir.ts +0 -40
- package/project/.sdk/src/cmp/elixir/Package_elixir.ts +0 -13
- package/project/.sdk/src/cmp/elixir/PrepareAuth_elixir.ts +0 -123
- package/project/.sdk/src/cmp/elixir/ReadmeExamplesTest_elixir.ts +0 -19
- package/project/.sdk/src/cmp/elixir/ReadmeRef_elixir.ts +2 -5
- package/project/.sdk/src/cmp/elixir/Schema_elixir.ts +0 -24
- package/project/.sdk/src/cmp/elixir/utility_elixir.ts +0 -34
- package/project/.sdk/src/cmp/go/Config_go.ts +0 -41
- package/project/.sdk/src/cmp/go/EntityTypes_go.ts +0 -71
- package/project/.sdk/src/cmp/go/Entity_go.ts +0 -5
- package/project/.sdk/src/cmp/go/Main_go.ts +0 -28
- package/project/.sdk/src/cmp/go/Package_go.ts +0 -7
- package/project/.sdk/src/cmp/go/PrepareAuth_go.ts +0 -64
- package/project/.sdk/src/cmp/go/ReadmeEntity_go.ts +0 -5
- package/project/.sdk/src/cmp/go/ReadmeExamplesTest_go.ts +0 -30
- package/project/.sdk/src/cmp/go/ReadmeHowto_go.ts +0 -3
- package/project/.sdk/src/cmp/go/ReadmeIntro_go.ts +0 -7
- package/project/.sdk/src/cmp/go/ReadmeModel_go.ts +0 -11
- package/project/.sdk/src/cmp/go/ReadmeQuick_go.ts +0 -21
- package/project/.sdk/src/cmp/go/ReadmeRef_go.ts +2 -14
- package/project/.sdk/src/cmp/go/ReadmeTopQuick_go.ts +0 -9
- package/project/.sdk/src/cmp/go/Schema_go.ts +0 -21
- package/project/.sdk/src/cmp/go/TestDirect_go.ts +0 -23
- package/project/.sdk/src/cmp/go/TestEntity_go.ts +0 -8
- package/project/.sdk/src/cmp/go/fragment/Entity.fragment.go +0 -21
- package/project/.sdk/src/cmp/go/fragment/Main.fragment.go +0 -12
- package/project/.sdk/src/cmp/go/utility_go.ts +0 -70
- package/project/.sdk/src/cmp/go-cli/Main_go-cli.ts +0 -49
- package/project/.sdk/src/cmp/go-cli/fragment/words.fragment.go +0 -12
- package/project/.sdk/src/cmp/go-mcp/Main_go-mcp.ts +0 -36
- package/project/.sdk/src/cmp/go-mcp/fragment/main.fragment.go +0 -20
- package/project/.sdk/src/cmp/go-mcp/fragment/tools.fragment.go +0 -3
- package/project/.sdk/src/cmp/java/Config_java.ts +0 -63
- package/project/.sdk/src/cmp/java/EntityTypes_java.ts +0 -50
- package/project/.sdk/src/cmp/java/Entity_java.ts +0 -6
- package/project/.sdk/src/cmp/java/Main_java.ts +0 -24
- package/project/.sdk/src/cmp/java/PrepareAuth_java.ts +0 -55
- package/project/.sdk/src/cmp/java/ReadmeEntity_java.ts +0 -1
- package/project/.sdk/src/cmp/java/ReadmeExamplesTest_java.ts +0 -20
- package/project/.sdk/src/cmp/java/ReadmeQuick_java.ts +0 -4
- package/project/.sdk/src/cmp/java/ReadmeRef_java.ts +2 -5
- package/project/.sdk/src/cmp/java/ReadmeTopQuick_java.ts +0 -7
- package/project/.sdk/src/cmp/java/Schema_java.ts +0 -19
- package/project/.sdk/src/cmp/java/TestDirect_java.ts +0 -7
- package/project/.sdk/src/cmp/java/TestEntity_java.ts +0 -4
- package/project/.sdk/src/cmp/java/Test_java.ts +0 -6
- package/project/.sdk/src/cmp/java/utility_java.ts +0 -33
- package/project/.sdk/src/cmp/js/Config_js.ts +0 -46
- package/project/.sdk/src/cmp/js/EntityTypes_js.ts +0 -33
- package/project/.sdk/src/cmp/js/Main_js.ts +0 -33
- package/project/.sdk/src/cmp/js/Package_js.ts +2 -7
- package/project/.sdk/src/cmp/js/PrepareAuth_js.ts +0 -57
- package/project/.sdk/src/cmp/js/ReadmeEntity_js.ts +0 -9
- package/project/.sdk/src/cmp/js/ReadmeHowto_js.ts +0 -2
- package/project/.sdk/src/cmp/js/ReadmeQuick_js.ts +0 -15
- package/project/.sdk/src/cmp/js/ReadmeRef_js.ts +2 -7
- package/project/.sdk/src/cmp/js/ReadmeTopQuick_js.ts +0 -7
- package/project/.sdk/src/cmp/js/Schema_js.ts +0 -21
- package/project/.sdk/src/cmp/js/TestDirect_js.ts +2 -16
- package/project/.sdk/src/cmp/js/TestEntity_js.ts +3 -13
- package/project/.sdk/src/cmp/js/TestLive_js.ts +10 -3
- package/project/.sdk/src/cmp/js/utility_js.ts +0 -58
- package/project/.sdk/src/cmp/kotlin/Config_kotlin.ts +0 -46
- package/project/.sdk/src/cmp/kotlin/EntityOperation_kotlin.ts +0 -2
- package/project/.sdk/src/cmp/kotlin/EntityTypes_kotlin.ts +0 -53
- package/project/.sdk/src/cmp/kotlin/Entity_kotlin.ts +0 -4
- package/project/.sdk/src/cmp/kotlin/Main_kotlin.ts +0 -46
- package/project/.sdk/src/cmp/kotlin/PrepareAuth_kotlin.ts +0 -113
- package/project/.sdk/src/cmp/kotlin/ReadmeEntity_kotlin.ts +0 -1
- package/project/.sdk/src/cmp/kotlin/ReadmeExamplesTest_kotlin.ts +0 -20
- package/project/.sdk/src/cmp/kotlin/ReadmeRef_kotlin.ts +2 -5
- package/project/.sdk/src/cmp/kotlin/ReadmeTopQuick_kotlin.ts +0 -5
- package/project/.sdk/src/cmp/kotlin/Schema_kotlin.ts +0 -19
- package/project/.sdk/src/cmp/kotlin/TestEntity_kotlin.ts +0 -4
- package/project/.sdk/src/cmp/kotlin/Test_kotlin.ts +0 -6
- package/project/.sdk/src/cmp/kotlin/utility_kotlin.ts +0 -33
- package/project/.sdk/src/cmp/lua/Config_lua.ts +0 -56
- package/project/.sdk/src/cmp/lua/EntityTypes_lua.ts +0 -30
- package/project/.sdk/src/cmp/lua/Entity_lua.ts +0 -7
- package/project/.sdk/src/cmp/lua/Main_lua.ts +0 -58
- package/project/.sdk/src/cmp/lua/Package_lua.ts +0 -20
- package/project/.sdk/src/cmp/lua/PrepareAuth_lua.ts +0 -61
- package/project/.sdk/src/cmp/lua/ReadmeEntity_lua.ts +0 -8
- package/project/.sdk/src/cmp/lua/ReadmeExamplesTest_lua.ts +0 -24
- package/project/.sdk/src/cmp/lua/ReadmeModel_lua.ts +0 -10
- package/project/.sdk/src/cmp/lua/ReadmeQuick_lua.ts +0 -21
- package/project/.sdk/src/cmp/lua/ReadmeRef_lua.ts +2 -12
- package/project/.sdk/src/cmp/lua/ReadmeTopQuick_lua.ts +0 -3
- package/project/.sdk/src/cmp/lua/Schema_lua.ts +0 -16
- package/project/.sdk/src/cmp/lua/TestDirect_lua.ts +0 -2
- package/project/.sdk/src/cmp/lua/utility_lua.ts +0 -30
- package/project/.sdk/src/cmp/ocaml/Config_ocaml.ts +0 -98
- package/project/.sdk/src/cmp/ocaml/EntityOperation_ocaml.ts +0 -6
- package/project/.sdk/src/cmp/ocaml/Main_ocaml.ts +0 -78
- package/project/.sdk/src/cmp/ocaml/Package_ocaml.ts +0 -13
- package/project/.sdk/src/cmp/ocaml/PrepareAuth_ocaml.ts +0 -145
- package/project/.sdk/src/cmp/ocaml/ReadmeExamplesTest_ocaml.ts +0 -17
- package/project/.sdk/src/cmp/ocaml/ReadmeRef_ocaml.ts +2 -5
- package/project/.sdk/src/cmp/ocaml/Schema_ocaml.ts +0 -23
- package/project/.sdk/src/cmp/ocaml/SdkError_ocaml.ts +0 -4
- package/project/.sdk/src/cmp/ocaml/TestEntity_ocaml.ts +0 -5
- package/project/.sdk/src/cmp/ocaml/utility_ocaml.ts +0 -27
- package/project/.sdk/src/cmp/perl/Config_perl.ts +0 -52
- package/project/.sdk/src/cmp/perl/Entity_perl.ts +0 -3
- package/project/.sdk/src/cmp/perl/Main_perl.ts +0 -33
- package/project/.sdk/src/cmp/perl/Package_perl.ts +0 -8
- package/project/.sdk/src/cmp/perl/PrepareAuth_perl.ts +0 -84
- package/project/.sdk/src/cmp/perl/ReadmeEntity_perl.ts +0 -3
- package/project/.sdk/src/cmp/perl/ReadmeExamplesTest_perl.ts +0 -27
- package/project/.sdk/src/cmp/perl/ReadmeRef_perl.ts +2 -5
- package/project/.sdk/src/cmp/perl/ReadmeTopQuick_perl.ts +0 -2
- package/project/.sdk/src/cmp/perl/Schema_perl.ts +0 -18
- package/project/.sdk/src/cmp/perl/TestDirect_perl.ts +0 -2
- package/project/.sdk/src/cmp/perl/utility_perl.ts +0 -26
- package/project/.sdk/src/cmp/php/Config_php.ts +0 -76
- package/project/.sdk/src/cmp/php/EntityTypes_php.ts +0 -51
- package/project/.sdk/src/cmp/php/MainEntity_php.ts +0 -6
- package/project/.sdk/src/cmp/php/Main_php.ts +0 -15
- package/project/.sdk/src/cmp/php/PrepareAuth_php.ts +0 -73
- package/project/.sdk/src/cmp/php/ReadmeEntity_php.ts +0 -4
- package/project/.sdk/src/cmp/php/ReadmeExamplesTest_php.ts +0 -33
- package/project/.sdk/src/cmp/php/ReadmeHowto_php.ts +0 -1
- package/project/.sdk/src/cmp/php/ReadmeQuick_php.ts +0 -19
- package/project/.sdk/src/cmp/php/ReadmeRef_php.ts +2 -7
- package/project/.sdk/src/cmp/php/Schema_php.ts +0 -15
- package/project/.sdk/src/cmp/php/TestEntity_php.ts +0 -9
- package/project/.sdk/src/cmp/php/utility_php.ts +0 -22
- package/project/.sdk/src/cmp/py/Config_py.ts +0 -53
- package/project/.sdk/src/cmp/py/EntityTypes_py.ts +0 -55
- package/project/.sdk/src/cmp/py/Entity_py.ts +0 -16
- package/project/.sdk/src/cmp/py/Main_py.ts +1 -61
- package/project/.sdk/src/cmp/py/Package_py.ts +0 -3
- package/project/.sdk/src/cmp/py/PrepareAuth_py.ts +0 -69
- package/project/.sdk/src/cmp/py/ReadmeEntity_py.ts +0 -13
- package/project/.sdk/src/cmp/py/ReadmeExamplesTest_py.ts +0 -31
- package/project/.sdk/src/cmp/py/ReadmeHowto_py.ts +0 -3
- package/project/.sdk/src/cmp/py/ReadmeQuick_py.ts +0 -28
- package/project/.sdk/src/cmp/py/ReadmeRef_py.ts +2 -16
- package/project/.sdk/src/cmp/py/ReadmeTopQuick_py.ts +0 -14
- package/project/.sdk/src/cmp/py/Schema_py.ts +0 -19
- package/project/.sdk/src/cmp/py/TestDirect_py.ts +0 -2
- package/project/.sdk/src/cmp/py/utility_py.ts +0 -22
- package/project/.sdk/src/cmp/py-data/Main_py-data.ts +9 -43
- package/project/.sdk/src/cmp/rb/Config_rb.ts +0 -56
- package/project/.sdk/src/cmp/rb/EntityTypes_rb.ts +0 -58
- package/project/.sdk/src/cmp/rb/Entity_rb.ts +0 -3
- package/project/.sdk/src/cmp/rb/Main_rb.ts +0 -10
- package/project/.sdk/src/cmp/rb/Package_rb.ts +0 -5
- package/project/.sdk/src/cmp/rb/PrepareAuth_rb.ts +0 -81
- package/project/.sdk/src/cmp/rb/ReadmeEntity_rb.ts +0 -7
- package/project/.sdk/src/cmp/rb/ReadmeExamplesTest_rb.ts +0 -32
- package/project/.sdk/src/cmp/rb/ReadmeHowto_rb.ts +0 -9
- package/project/.sdk/src/cmp/rb/ReadmeQuick_rb.ts +0 -23
- package/project/.sdk/src/cmp/rb/ReadmeRef_rb.ts +2 -10
- package/project/.sdk/src/cmp/rb/ReadmeTopQuick_rb.ts +0 -5
- package/project/.sdk/src/cmp/rb/ReadmeTopTest_rb.ts +0 -3
- package/project/.sdk/src/cmp/rb/Schema_rb.ts +0 -15
- package/project/.sdk/src/cmp/rb/TestDirect_rb.ts +0 -2
- package/project/.sdk/src/cmp/rb/utility_rb.ts +0 -22
- package/project/.sdk/src/cmp/rust/Config_rust.ts +0 -35
- package/project/.sdk/src/cmp/rust/EntityTypes_rust.ts +0 -34
- package/project/.sdk/src/cmp/rust/Entity_rust.ts +0 -9
- package/project/.sdk/src/cmp/rust/Main_rust.ts +0 -58
- package/project/.sdk/src/cmp/rust/Package_rust.ts +0 -30
- package/project/.sdk/src/cmp/rust/PrepareAuth_rust.ts +0 -84
- package/project/.sdk/src/cmp/rust/ReadmeExamplesTest_rust.ts +0 -16
- package/project/.sdk/src/cmp/rust/ReadmeRef_rust.ts +2 -5
- package/project/.sdk/src/cmp/rust/Schema_rust.ts +0 -18
- package/project/.sdk/src/cmp/rust/TestDirect_rust.ts +0 -7
- package/project/.sdk/src/cmp/rust/TestEntity_rust.ts +0 -9
- package/project/.sdk/src/cmp/rust/fragment/Entity.fragment.rs +0 -14
- package/project/.sdk/src/cmp/rust/fragment/EntityRemoveOp.fragment.rs +0 -4
- package/project/.sdk/src/cmp/rust/fragment/Main.fragment.rs +0 -20
- package/project/.sdk/src/cmp/rust/fragment/SdkError.fragment.rs +0 -6
- package/project/.sdk/src/cmp/rust/utility_rust.ts +0 -47
- package/project/.sdk/src/cmp/scala/Config_scala.ts +0 -31
- package/project/.sdk/src/cmp/scala/EntityTypes_scala.ts +0 -51
- package/project/.sdk/src/cmp/scala/Main_scala.ts +0 -78
- package/project/.sdk/src/cmp/scala/PrepareAuth_scala.ts +0 -102
- package/project/.sdk/src/cmp/scala/ReadmeEntity_scala.ts +0 -1
- package/project/.sdk/src/cmp/scala/ReadmeExamplesTest_scala.ts +0 -23
- package/project/.sdk/src/cmp/scala/ReadmeRef_scala.ts +2 -5
- package/project/.sdk/src/cmp/scala/ReadmeTopQuick_scala.ts +0 -5
- package/project/.sdk/src/cmp/scala/Schema_scala.ts +0 -19
- package/project/.sdk/src/cmp/scala/TestEntity_scala.ts +0 -8
- package/project/.sdk/src/cmp/scala/Test_scala.ts +0 -3
- package/project/.sdk/src/cmp/scala/utility_scala.ts +0 -31
- package/project/.sdk/src/cmp/swift/Config_swift.ts +0 -62
- package/project/.sdk/src/cmp/swift/EntityOperation_swift.ts +0 -3
- package/project/.sdk/src/cmp/swift/EntityTypes_swift.ts +0 -39
- package/project/.sdk/src/cmp/swift/Main_swift.ts +0 -42
- package/project/.sdk/src/cmp/swift/Package_swift.ts +0 -69
- package/project/.sdk/src/cmp/swift/PrepareAuth_swift.ts +0 -134
- package/project/.sdk/src/cmp/swift/ReadmeEntity_swift.ts +0 -2
- package/project/.sdk/src/cmp/swift/ReadmeExamplesTest_swift.ts +0 -22
- package/project/.sdk/src/cmp/swift/ReadmeRef_swift.ts +2 -5
- package/project/.sdk/src/cmp/swift/Schema_swift.ts +0 -18
- package/project/.sdk/src/cmp/swift/TestEntity_swift.ts +0 -4
- package/project/.sdk/src/cmp/swift/utility_swift.ts +0 -51
- package/project/.sdk/src/cmp/ts/Config_ts.ts +0 -46
- package/project/.sdk/src/cmp/ts/EntityTypes_ts.ts +0 -34
- package/project/.sdk/src/cmp/ts/Entity_ts.ts +0 -6
- package/project/.sdk/src/cmp/ts/Main_ts.ts +0 -28
- package/project/.sdk/src/cmp/ts/Package_ts.ts +2 -26
- package/project/.sdk/src/cmp/ts/PrepareAuth_ts.ts +0 -55
- package/project/.sdk/src/cmp/ts/ReadmeEntity_ts.ts +0 -9
- package/project/.sdk/src/cmp/ts/ReadmeExampleTest_ts.ts +0 -6
- package/project/.sdk/src/cmp/ts/ReadmeExamplesTest_ts.ts +0 -25
- package/project/.sdk/src/cmp/ts/ReadmeHowto_ts.ts +4 -9
- package/project/.sdk/src/cmp/ts/ReadmeIntro_ts.ts +0 -7
- package/project/.sdk/src/cmp/ts/ReadmeModel_ts.ts +0 -3
- package/project/.sdk/src/cmp/ts/ReadmeQuick_ts.ts +0 -43
- package/project/.sdk/src/cmp/ts/ReadmeRef_ts.ts +2 -20
- package/project/.sdk/src/cmp/ts/ReadmeTopQuick_ts.ts +0 -11
- package/project/.sdk/src/cmp/ts/ReadmeTopTest_ts.ts +6 -9
- package/project/.sdk/src/cmp/ts/Schema_ts.ts +0 -21
- package/project/.sdk/src/cmp/ts/TestDirect_ts.ts +2 -53
- package/project/.sdk/src/cmp/ts/TestEntity_ts.ts +3 -31
- package/project/.sdk/src/cmp/ts/TestLive_ts.ts +10 -4
- package/project/.sdk/src/cmp/ts/Test_ts.ts +0 -4
- package/project/.sdk/src/cmp/ts/fragment/Config.data.fragment.ts +0 -27
- package/project/.sdk/src/cmp/ts/fragment/Config.fragment.ts +0 -7
- package/project/.sdk/src/cmp/ts/fragment/Direct.test.fragment.ts +0 -7
- package/project/.sdk/src/cmp/ts/fragment/Entity.fragment.ts +0 -1
- package/project/.sdk/src/cmp/ts/fragment/Entity.test.fragment.ts +0 -4
- package/project/.sdk/src/cmp/ts/fragment/EntityBase.fragment.ts +0 -20
- package/project/.sdk/src/cmp/ts/fragment/EntityCreateOp.fragment.ts +0 -6
- package/project/.sdk/src/cmp/ts/fragment/EntityLoadOp.fragment.ts +0 -6
- package/project/.sdk/src/cmp/ts/fragment/EntityRemoveOp.fragment.ts +0 -15
- package/project/.sdk/src/cmp/ts/fragment/EntityUpdateOp.fragment.ts +0 -6
- package/project/.sdk/src/cmp/ts/fragment/Main.fragment.ts +0 -15
- package/project/.sdk/src/cmp/ts/fragment/MainStation.fragment.ts +0 -12
- package/project/.sdk/src/cmp/ts/fragment/SdkError.fragment.ts +0 -9
- package/project/.sdk/src/cmp/ts/utility_ts.ts +0 -59
- package/project/.sdk/src/cmp/zig/Config_zig.ts +0 -70
- package/project/.sdk/src/cmp/zig/Entity_zig.ts +0 -3
- package/project/.sdk/src/cmp/zig/Main_zig.ts +0 -83
- package/project/.sdk/src/cmp/zig/Package_zig.ts +0 -22
- package/project/.sdk/src/cmp/zig/PrepareAuth_zig.ts +0 -136
- package/project/.sdk/src/cmp/zig/ReadmeExamplesTest_zig.ts +0 -18
- package/project/.sdk/src/cmp/zig/ReadmeQuick_zig.ts +0 -3
- package/project/.sdk/src/cmp/zig/ReadmeRef_zig.ts +2 -5
- package/project/.sdk/src/cmp/zig/Schema_zig.ts +0 -23
- package/project/.sdk/src/cmp/zig/TestDirect_zig.ts +0 -11
- package/project/.sdk/src/cmp/zig/TestEntity_zig.ts +0 -8
- package/project/.sdk/src/cmp/zig/Test_zig.ts +0 -11
- package/project/.sdk/src/cmp/zig/utility_zig.ts +0 -47
- package/project/.sdk/tm/csharp/feature/FeatureOptions.cs +18 -5
- package/project/.sdk/tm/go/core/context.go +0 -9
- package/project/.sdk/tm/go/core/types.go +0 -3
- package/project/.sdk/tm/go/feature/audit_feature.go +0 -9
- package/project/.sdk/tm/go/feature/cache_feature.go +0 -8
- package/project/.sdk/tm/go/feature/clienttrack_feature.go +0 -7
- package/project/.sdk/tm/go/feature/cost_feature.go +0 -51
- package/project/.sdk/tm/go/feature/debug_feature.go +0 -6
- package/project/.sdk/tm/go/feature/feature_options.go +108 -21
- package/project/.sdk/tm/go/feature/idempotency_feature.go +0 -6
- package/project/.sdk/tm/go/feature/metrics_feature.go +0 -6
- package/project/.sdk/tm/go/feature/netsim_feature.go +0 -8
- package/project/.sdk/tm/go/feature/paging_feature.go +0 -9
- package/project/.sdk/tm/go/feature/proxy_feature.go +0 -7
- package/project/.sdk/tm/go/feature/ratelimit_feature.go +0 -6
- package/project/.sdk/tm/go/feature/rbac_feature.go +0 -10
- package/project/.sdk/tm/go/feature/retry_feature.go +0 -6
- package/project/.sdk/tm/go/feature/secrets_feature.go +0 -173
- package/project/.sdk/tm/go/feature/streaming_feature.go +0 -7
- package/project/.sdk/tm/go/feature/telemetry_feature.go +0 -8
- package/project/.sdk/tm/go/feature/test_feature.go +0 -23
- package/project/.sdk/tm/go/feature/validate_feature.go +0 -66
- package/project/.sdk/tm/go/test/custom_utility_test.go +0 -29
- package/project/.sdk/tm/go/test/feature/secrets/secrets_feature_test.go +0 -100
- package/project/.sdk/tm/go/test/feature_corpus_test.go +1 -60
- package/project/.sdk/tm/go/test/feature_harness_test.go +0 -10
- package/project/.sdk/tm/go/test/feature_test.go +107 -9
- package/project/.sdk/tm/go/test/omniresolver_test.go +0 -74
- package/project/.sdk/tm/go/test/omnismoke_test.go +0 -4
- package/project/.sdk/tm/go/test/pipeline_test.go +0 -10
- package/project/.sdk/tm/go/test/primary_utility_test.go +0 -32
- package/project/.sdk/tm/go/test/struct_utility_test.go +0 -38
- package/project/.sdk/tm/go/test/testsupport_test.go +0 -25
- package/project/.sdk/tm/go/utility/feature_add.go +0 -6
- package/project/.sdk/tm/go/utility/fetcher.go +0 -6
- package/project/.sdk/tm/go/utility/graphql.go +1 -31
- package/project/.sdk/tm/go/utility/make_options.go +38 -49
- package/project/.sdk/tm/go/utility/make_point.go +0 -11
- package/project/.sdk/tm/go/utility/make_spec.go +0 -15
- package/project/.sdk/tm/go/utility/register.go +0 -28
- package/project/.sdk/tm/go/utility/transform_request.go +0 -20
- package/project/.sdk/tm/go/utility/transform_response.go +0 -8
- package/project/.sdk/tm/js/src/feature/test/TestFeature.js +12 -4
- package/project/.sdk/tm/rust/core/context.rs +0 -5
- package/project/.sdk/tm/rust/core/control.rs +0 -1
- package/project/.sdk/tm/rust/core/helpers.rs +0 -15
- package/project/.sdk/tm/rust/core/operation.rs +0 -1
- package/project/.sdk/tm/rust/core/point.rs +0 -3
- package/project/.sdk/tm/rust/core/response.rs +0 -2
- package/project/.sdk/tm/rust/core/result.rs +0 -1
- package/project/.sdk/tm/rust/core/spec.rs +0 -1
- package/project/.sdk/tm/rust/core/types.rs +0 -20
- package/project/.sdk/tm/rust/core/utility_type.rs +0 -5
- package/project/.sdk/tm/rust/feature/audit.rs +0 -9
- package/project/.sdk/tm/rust/feature/base.rs +0 -3
- package/project/.sdk/tm/rust/feature/cache.rs +0 -9
- package/project/.sdk/tm/rust/feature/clienttrack.rs +0 -7
- package/project/.sdk/tm/rust/feature/cost.rs +0 -48
- package/project/.sdk/tm/rust/feature/debug.rs +0 -7
- package/project/.sdk/tm/rust/feature/idempotency.rs +0 -7
- package/project/.sdk/tm/rust/feature/log.rs +0 -3
- package/project/.sdk/tm/rust/feature/metrics.rs +0 -7
- package/project/.sdk/tm/rust/feature/netsim.rs +0 -9
- package/project/.sdk/tm/rust/feature/paging.rs +0 -10
- package/project/.sdk/tm/rust/feature/proxy.rs +0 -8
- package/project/.sdk/tm/rust/feature/ratelimit.rs +0 -6
- package/project/.sdk/tm/rust/feature/rbac.rs +0 -10
- package/project/.sdk/tm/rust/feature/retry.rs +0 -6
- package/project/.sdk/tm/rust/feature/secrets.rs +1 -187
- package/project/.sdk/tm/rust/feature/streaming.rs +0 -7
- package/project/.sdk/tm/rust/feature/support.rs +0 -6
- package/project/.sdk/tm/rust/feature/telemetry.rs +0 -9
- package/project/.sdk/tm/rust/feature/test.rs +0 -19
- package/project/.sdk/tm/rust/feature/timeout.rs +0 -7
- package/project/.sdk/tm/rust/feature/validate.rs +0 -81
- package/project/.sdk/tm/rust/tests/common/mod.rs +0 -35
- package/project/.sdk/tm/rust/tests/custom_utility_test.rs +0 -2
- package/project/.sdk/tm/rust/tests/feature/secrets/main.rs +0 -95
- package/project/.sdk/tm/rust/tests/feature_test.rs +0 -16
- package/project/.sdk/tm/rust/tests/netsim_test.rs +0 -6
- package/project/.sdk/tm/rust/tests/omni_resolver/mod.rs +0 -135
- package/project/.sdk/tm/rust/tests/omni_smoke_test.rs +0 -15
- package/project/.sdk/tm/rust/tests/pipeline_test.rs +0 -6
- package/project/.sdk/tm/rust/tests/primary_utility_test.rs +0 -22
- package/project/.sdk/tm/rust/tests/struct_utility_test.rs +0 -25
- package/project/.sdk/tm/rust/utility/fetcher.rs +0 -5
- package/project/.sdk/tm/rust/utility/graphql.rs +1 -30
- package/project/.sdk/tm/rust/utility/make_error.rs +0 -2
- package/project/.sdk/tm/rust/utility/make_options.rs +0 -46
- package/project/.sdk/tm/rust/utility/make_point.rs +0 -12
- package/project/.sdk/tm/rust/utility/make_spec.rs +0 -4
- package/project/.sdk/tm/rust/utility/voxgigstruct/consts.rs +14 -20
- package/project/.sdk/tm/rust/utility/voxgigstruct/major.rs +0 -13
- package/project/.sdk/tm/rust/utility/voxgigstruct/mini.rs +0 -14
- package/project/.sdk/tm/rust/utility/voxgigstruct/mod.rs +0 -2
- package/project/.sdk/tm/rust/utility/voxgigstruct/ordered_map.rs +0 -18
- package/project/.sdk/tm/rust/utility/voxgigstruct/re.rs +0 -11
- package/project/.sdk/tm/rust/utility/voxgigstruct/value.rs +0 -3
- package/project/.sdk/tm/ts/src/Context.ts +0 -5
- package/project/.sdk/tm/ts/src/feature/audit/AuditFeature.ts +0 -7
- package/project/.sdk/tm/ts/src/feature/cache/CacheFeature.ts +0 -8
- package/project/.sdk/tm/ts/src/feature/clienttrack/ClienttrackFeature.ts +0 -7
- package/project/.sdk/tm/ts/src/feature/cost/CostFeature.ts +0 -52
- package/project/.sdk/tm/ts/src/feature/debug/DebugFeature.ts +0 -6
- package/project/.sdk/tm/ts/src/feature/metrics/MetricsFeature.ts +0 -6
- package/project/.sdk/tm/ts/src/feature/netsim/NetsimFeature.ts +0 -8
- package/project/.sdk/tm/ts/src/feature/paging/PagingFeature.ts +0 -13
- package/project/.sdk/tm/ts/src/feature/proxy/ProxyFeature.ts +0 -8
- package/project/.sdk/tm/ts/src/feature/ratelimit/RatelimitFeature.ts +0 -6
- package/project/.sdk/tm/ts/src/feature/rbac/RbacFeature.ts +0 -9
- package/project/.sdk/tm/ts/src/feature/retry/RetryFeature.ts +0 -6
- package/project/.sdk/tm/ts/src/feature/secrets/SecretsFeature.ts +0 -136
- package/project/.sdk/tm/ts/src/feature/streaming/StreamingFeature.ts +0 -7
- package/project/.sdk/tm/ts/src/feature/telemetry/TelemetryFeature.ts +0 -7
- package/project/.sdk/tm/ts/src/feature/test/TestFeature.ts +13 -88
- package/project/.sdk/tm/ts/src/feature/validate/ValidateFeature.ts +0 -87
- package/project/.sdk/tm/ts/src/utility/CleanUtility.ts +0 -12
- package/project/.sdk/tm/ts/src/utility/FeatureAddUtility.ts +0 -1
- package/project/.sdk/tm/ts/src/utility/GraphqlUtility.ts +2 -30
- package/project/.sdk/tm/ts/src/utility/MakeErrorUtility.ts +0 -4
- package/project/.sdk/tm/ts/src/utility/MakeOptionsUtility.ts +0 -46
- package/project/.sdk/tm/ts/src/utility/MakePointUtility.ts +0 -34
- package/project/.sdk/tm/ts/src/utility/MakeRequestUtility.ts +0 -1
- package/project/.sdk/tm/ts/src/utility/MakeSpecUtility.ts +0 -5
- package/project/.sdk/tm/ts/src/utility/MakeUrlUtility.ts +0 -1
- package/project/.sdk/tm/ts/src/utility/ParamUtility.ts +0 -8
- package/project/.sdk/tm/ts/src/utility/PrepareBodyUtility.ts +0 -3
- package/project/.sdk/tm/ts/src/utility/PrepareParamsUtility.ts +0 -6
- package/project/.sdk/tm/ts/src/utility/ResultBasicUtility.ts +0 -1
- package/project/.sdk/tm/ts/src/utility/TransformRequestUtility.ts +0 -20
- package/project/.sdk/tm/ts/src/utility/TransformResponseUtility.ts +0 -4
- package/project/.sdk/tm/ts/test/exists.test.ts +0 -10
- package/project/.sdk/tm/ts/test/feature/Corpus.test.ts +0 -56
- package/project/.sdk/tm/ts/test/feature/harness.ts +0 -9
- package/project/.sdk/tm/ts/test/feature/secrets/Secrets.test.ts +0 -106
- package/project/.sdk/tm/ts/test/live-contract.ts +0 -2
- package/project/.sdk/tm/ts/test/omni.ts +0 -32
- package/project/.sdk/tm/ts/test/pipeline.test.ts +45 -28
- package/project/.sdk/tm/ts/test/utility/Corpus.test.ts +0 -13
- package/project/.sdk/tm/ts/test/utility/PrimaryUtility.test.ts +56 -29
- package/project/.sdk/tm/ts/test/utility/StructUtility.test.ts +0 -7
- package/project/.sdk/tm/ts/test/utility.ts +0 -55
- package/project/sdkgen-package.json +1 -1
- package/src/action/action.ts +0 -65
- package/src/action/check.ts +0 -88
- package/src/action/dispatch.ts +0 -27
- package/src/action/doctor.ts +69 -329
- package/src/action/edition.ts +1 -87
- package/src/action/feature.ts +1 -49
- package/src/action/kind.ts +0 -149
- package/src/action/package.ts +0 -228
- package/src/action/resolve.ts +0 -148
- package/src/action/target.ts +0 -177
- package/src/cmp/AgentGuide.ts +0 -7
- package/src/cmp/AgentGuideContent.ts +0 -24
- package/src/cmp/AgentGuideTop.ts +0 -7
- package/src/cmp/Changelog.ts +0 -14
- package/src/cmp/Deploy.ts +1 -31
- package/src/cmp/Entity.ts +0 -4
- package/src/cmp/ExternalTarget.ts +0 -36
- package/src/cmp/Feature.ts +0 -14
- package/src/cmp/FeatureDocs.ts +0 -37
- package/src/cmp/PublishWorkflow.ts +0 -60
- package/src/cmp/ReadmeErrors.ts +0 -17
- package/src/cmp/ReadmeExplanation.ts +2 -11
- package/src/cmp/ReadmeFeatures.ts +0 -10
- package/src/cmp/ReadmeRefFeatures.ts +0 -19
- package/src/cmp/ReadmeStation.ts +0 -19
- package/src/cmp/ReadmeTop.ts +0 -80
- package/src/cmp/ReadmeUnions.ts +0 -15
- package/src/cmp/Registered.ts +0 -30
- package/src/cmp/Security.ts +0 -2
- package/src/cmp/Test.ts +3 -1
- package/src/cmp/TestControl.ts +0 -25
- package/src/helpers/applicability.ts +0 -60
- package/src/helpers/buildIdNames.ts +0 -12
- package/src/helpers/canonSpec.ts +0 -114
- package/src/helpers/canonType.ts +0 -87
- package/src/helpers/collectDeps.ts +0 -27
- package/src/helpers/definition.ts +0 -29
- package/src/helpers/dryrun.ts +0 -8
- package/src/helpers/featureSource.ts +0 -152
- package/src/helpers/getMatchEntries.ts +0 -4
- package/src/helpers/junk.ts +13 -89
- package/src/helpers/manifest.ts +0 -169
- package/src/helpers/modelNames.ts +0 -81
- package/src/helpers/modelcheck.ts +0 -106
- package/src/helpers/naming.ts +0 -303
- package/src/helpers/opExample.ts +0 -56
- package/src/helpers/opShape.ts +0 -200
- package/src/helpers/optspec.ts +0 -77
- package/src/helpers/packageMeta.ts +1 -200
- package/src/helpers/pointPath.ts +0 -55
- package/src/helpers/resolved.ts +50 -0
- package/src/helpers/semver.ts +0 -61
- package/src/helpers/serverVars.ts +0 -44
- package/src/helpers/shipped.ts +0 -14
- package/src/helpers/station.ts +0 -32
- package/src/helpers/stdrep.ts +0 -52
- package/src/helpers/testPolicy.ts +0 -4
- package/src/sdkgen.ts +15 -263
- package/src/testkit.ts +6 -312
- package/src/types.ts +1 -30
- package/src/utility.ts +0 -243
|
@@ -1,25 +1,4 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
// Which features a target can actually take.
|
|
3
|
-
//
|
|
4
|
-
// THE ONE PLACE THIS RULE LIVES. `Feature` (what source is copied), the
|
|
5
|
-
// per-language `Config_<lang>` and `Main_<lang>` components (what the
|
|
6
|
-
// generated registry, imports and metadata contain) and `configDefinition`
|
|
7
|
-
// (the embedded config) must all reach the same answer for one
|
|
8
|
-
// (feature, target) pair. They previously each read the raw feature map,
|
|
9
|
-
// which is how a feature with no source for a target still reached that
|
|
10
|
-
// target's imports.
|
|
11
|
-
//
|
|
12
|
-
// The shape is `docs/design/feature-tags.md`: a feature declares what it
|
|
13
|
-
// NEEDS, a target declares what it PROVIDES, and the feature applies when
|
|
14
|
-
// `needs` is a subset of `provides`. Both default to empty, so a feature
|
|
15
|
-
// that needs nothing applies everywhere — every feature that existed
|
|
16
|
-
// before this gate keeps its behaviour with no model edit, which is what
|
|
17
|
-
// makes the change additive.
|
|
18
|
-
//
|
|
19
|
-
// A named target list was the cheaper design and fails on time: it has to
|
|
20
|
-
// be edited for targets the feature's author has never heard of, so a
|
|
21
|
-
// published package starves every target added after its release. A tag is
|
|
22
|
-
// a claim about the feature that stays true as the target set grows.
|
|
23
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
24
3
|
exports.TAGS = void 0;
|
|
25
4
|
exports.featureApplies = featureApplies;
|
|
@@ -27,15 +6,6 @@ exports.targetFeatures = targetFeatures;
|
|
|
27
6
|
exports.featureTags = tags;
|
|
28
7
|
exports.unknownTags = unknownTags;
|
|
29
8
|
const apidef_1 = require("@voxgig/apidef");
|
|
30
|
-
// Tags are a MAP keyed by tag name, `{ sekreto: true }` — see the schema
|
|
31
|
-
// note on `needs`. A map because aontu unifies maps by key, so a package
|
|
32
|
-
// can add one tag without restating the others; and because a defaulted
|
|
33
|
-
// list disjunction in this position hangs the unifier on a real project's
|
|
34
|
-
// model. A tag counts only when its value is true, so a tag can be turned
|
|
35
|
-
// off by overriding it rather than by deleting the key.
|
|
36
|
-
//
|
|
37
|
-
// A list is still accepted, for a hand-written model that used the shape
|
|
38
|
-
// docs/design/feature-tags.md first proposed.
|
|
39
9
|
function tags(val) {
|
|
40
10
|
if (Array.isArray(val)) {
|
|
41
11
|
return val.filter((t) => 'string' === typeof t);
|
|
@@ -48,20 +18,12 @@ function tags(val) {
|
|
|
48
18
|
// Does this feature apply to this target?
|
|
49
19
|
function featureApplies(feature, target) {
|
|
50
20
|
const needs = tags(feature && feature.needs);
|
|
51
|
-
// The common case, and the reason this is additive: no needs, applies
|
|
52
|
-
// anywhere. Checked first so a target with no `provides` is unaffected.
|
|
53
21
|
if (0 === needs.length) {
|
|
54
22
|
return true;
|
|
55
23
|
}
|
|
56
24
|
const provides = tags(target && target.provides);
|
|
57
25
|
return needs.every((need) => provides.includes(need));
|
|
58
26
|
}
|
|
59
|
-
// The features that apply to `target`, in the same map shape
|
|
60
|
-
// `getModelPath(model, 'main.<kit>.feature')` returns — already
|
|
61
|
-
// active-filtered by getModelPath, then gated by the tags.
|
|
62
|
-
//
|
|
63
|
-
// `target` may be the target object or its name; components hold the
|
|
64
|
-
// object, `configDefinition` is only given the name.
|
|
65
27
|
function targetFeatures(model, target) {
|
|
66
28
|
const feature = (0, apidef_1.getModelPath)(model, `main.${apidef_1.KIT}.feature`, { required: false }) || {};
|
|
67
29
|
const t = 'string' === typeof target ?
|
|
@@ -72,10 +34,6 @@ function targetFeatures(model, target) {
|
|
|
72
34
|
if (null == t) {
|
|
73
35
|
return feature;
|
|
74
36
|
}
|
|
75
|
-
// Keyed off the map, not off `f.name`: the key is what every consumer
|
|
76
|
-
// indexes by, and rebuilding from a field would drop an entry whose
|
|
77
|
-
// model never set one. Order is not preserved on purpose — consumers
|
|
78
|
-
// re-sort with `each`, which is what keeps output byte-stable.
|
|
79
37
|
const applies = {};
|
|
80
38
|
for (const [name, f] of Object.entries(feature)) {
|
|
81
39
|
if (featureApplies(f, t)) {
|
|
@@ -84,27 +42,9 @@ function targetFeatures(model, target) {
|
|
|
84
42
|
}
|
|
85
43
|
return applies;
|
|
86
44
|
}
|
|
87
|
-
// THE CLOSED VOCABULARY. The schema comment says applicability tags are a
|
|
88
|
-
// closed set; without this, `provides: &: boolean` accepts any key, so a
|
|
89
|
-
// typo (`sekrreto`) compiles cleanly and silently makes the feature apply
|
|
90
|
-
// NOWHERE — the worst failure shape, because the feature simply vanishes
|
|
91
|
-
// with no diagnostic.
|
|
92
|
-
//
|
|
93
|
-
// Extended by adding a tag here AND documenting it in model/sdkgen.aon.
|
|
94
45
|
const TAGS = [
|
|
95
46
|
// A vendored sekreto port lives in this target's feature container.
|
|
96
47
|
'sekreto',
|
|
97
|
-
// The target can VALIDATE against the generated `Schema` module: the
|
|
98
|
-
// model's option spec and, when a feature asks for them, per-entity
|
|
99
|
-
// struct.validate specs.
|
|
100
|
-
//
|
|
101
|
-
// NOT "emits Schema". Every target emits one — make_options reads the
|
|
102
|
-
// option spec out of it — so that claim is universal and gates nothing.
|
|
103
|
-
// This tag is the `validate` FEATURE's `needs`, and a feature
|
|
104
|
-
// also needs its per-target source: tagging a target that has no
|
|
105
|
-
// `tm/<lang>/src/feature/validate/` makes the feature apply with nothing
|
|
106
|
-
// to copy. featuremodel.test.ts holds the two together in both
|
|
107
|
-
// directions.
|
|
108
48
|
'schema',
|
|
109
49
|
];
|
|
110
50
|
exports.TAGS = TAGS;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"applicability.js","sourceRoot":"","sources":["../../src/helpers/applicability.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"applicability.js","sourceRoot":"","sources":["../../src/helpers/applicability.ts"],"names":[],"mappings":";;;QAsEE,cAAc;QACd,cAAc;QACN,WAAW;QACnB,WAAW;AAxEb,2CAAkD;AAGlD,SAAS,IAAI,CAAC,GAAQ;IACpB,IAAI,KAAK,CAAC,OAAO,CAAC,GAAG,CAAC,EAAE,CAAC;QACvB,OAAO,GAAG,CAAC,MAAM,CAAC,CAAC,CAAM,EAAE,EAAE,CAAC,QAAQ,KAAK,OAAO,CAAC,CAAC,CAAA;IACtD,CAAC;IAED,IAAI,IAAI,IAAI,GAAG,IAAI,QAAQ,KAAK,OAAO,GAAG,EAAE,CAAC;QAC3C,OAAO,EAAE,CAAA;IACX,CAAC;IAED,OAAO,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,MAAM,CAAC,CAAC,IAAY,EAAE,EAAE,CAAC,IAAI,KAAK,GAAG,CAAC,IAAI,CAAC,CAAC,CAAA;AACtE,CAAC;AAGD,0CAA0C;AAC1C,SAAS,cAAc,CAAC,OAAY,EAAE,MAAW;IAC/C,MAAM,KAAK,GAAG,IAAI,CAAC,OAAO,IAAI,OAAO,CAAC,K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EAAuE;AACvE,SAAS,WAAW,CAAC,GAAQ;IAC3B,OAAO,IAAI,CAAC,GAAG,CAAC,CAAC,MAAM,CAAC,CAAC,CAAS,EAAE,EAAE,CAAC,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAA;AAC3D,CAAC"}
|
|
@@ -1,16 +1,4 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
// Build the list of placeholder ID names that the test setup populates into
|
|
3
|
-
// `setup.idmap`. The set is the union of:
|
|
4
|
-
// - the entity's own ids (`<entity>01..03`)
|
|
5
|
-
// - every ancestor entity's ids (`<anc>01..03`)
|
|
6
|
-
// - every literal string value referenced by `step.match` across the flow
|
|
7
|
-
// (e.g. path-parameter aliases like `year01` for `/{year}/domain` — apidef
|
|
8
|
-
// doesn't always populate `relations.ancestors` when the parent in the
|
|
9
|
-
// path is a bare parameter rather than an entity, so we have to mine the
|
|
10
|
-
// flow steps directly to avoid KeyError-ing the idmap from generated test
|
|
11
|
-
// code)
|
|
12
|
-
//
|
|
13
|
-
// Identical helper was previously inlined in TestEntity_{go,py,lua,rb,php}.ts.
|
|
14
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
3
|
exports.buildIdNames = buildIdNames;
|
|
16
4
|
const COUNT = 3; // 3 ids per name: <name>01, <name>02, <name>03
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"buildIdNames.js","sourceRoot":"","sources":["../../src/helpers/buildIdNames.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"buildIdNames.js","sourceRoot":"","sources":["../../src/helpers/buildIdNames.ts"],"names":[],"mappings":";;QAwDE,YAAY;AAvDd,MAAM,KAAK,GAAG,CAAC,CAAA,CAAC,+CAA+C;AAa/D,SAAS,YAAY,CAAC,MAAkB,EAAE,IAAc;IACtD,MAAM,OAAO,GAAa,EAAE,CAAA;IAC5B,MAAM,IAAI,GAAG,IAAI,GAAG,EAAU,CAAA;IAC9B,MAAM,IAAI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E;QACrE,wEAAwE;QACxE,4CAA4C;QAC5C,IAAI,IAAI,EAAE,IAAI,EAAE,CAAC;YACf,KAAK,MAAM,CAAC,IAAI,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC;gBACzC,IAAI,OAAO,CAAC,KAAK,QAAQ,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,QAAQ,CAAC,GAAG,CAAC;oBAAE,IAAI,CAAC,CAAC,CAAC,CAAA;YAC7D,CAAC;QACH,CAAC;IACH,CAAC;IAED,OAAO,OAAO,CAAA;AAChB,CAAC"}
|
|
@@ -1,43 +1,4 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
// Canonical type-sentinel -> struct.validate SPEC mapper.
|
|
3
|
-
//
|
|
4
|
-
// The sibling of canonType: that table turns a field's canon sentinel into a
|
|
5
|
-
// language TYPE NAME (what the generated source declares); this one turns the
|
|
6
|
-
// same sentinel into a struct.validate SPEC VALUE (what the generated runtime
|
|
7
|
-
// checks a payload against). One vocabulary, two renderings, and — as with
|
|
8
|
-
// canonType — a SINGLE mapping that components must not copy locally.
|
|
9
|
-
//
|
|
10
|
-
// WHY THIS IS ALMOST NOTHING. apidef stores `$STRING`, `$INTEGER`, `$NUMBER`,
|
|
11
|
-
// `$BOOLEAN`, `$NULL`, `$ARRAY`, `$OBJECT`, `$ANY` on `fields[].type`, and
|
|
12
|
-
// struct.validate's own vocabulary is `$STRING $NUMBER $INTEGER $DECIMAL
|
|
13
|
-
// $BOOLEAN $NULL $NIL $MAP $LIST $FUNCTION $INSTANCE $ANY $CHILD $ONE $EXACT`.
|
|
14
|
-
// Six of the eight scalar names are the IDENTICAL string. Only three things
|
|
15
|
-
// have to be adapted, and each is a real difference rather than a translation:
|
|
16
|
-
//
|
|
17
|
-
// 1. CONTAINERS ARE NAMED DIFFERENTLY. apidef speaks OpenAPI ($ARRAY,
|
|
18
|
-
// $OBJECT), struct speaks its own value model ($LIST, $MAP).
|
|
19
|
-
//
|
|
20
|
-
// 2. UNIONS ARE SHAPED DIFFERENTLY. apidef nests the members —
|
|
21
|
-
// ['`$ONE`', [a, b]] — and struct wants them flat: ['`$ONE`', a, b].
|
|
22
|
-
// The nested form does not fail loudly, which is the trap: struct reads
|
|
23
|
-
// the inner LIST as a single alternative, so `['`$ONE`', ['`$STRING`',
|
|
24
|
-
// '`$INTEGER`']]` rejects the string 'x' with "expected [string,integer]".
|
|
25
|
-
//
|
|
26
|
-
// 3. STRUCT'S `$STRING` REJECTS THE EMPTY STRING. That is right for an
|
|
27
|
-
// option (an empty apikey is a missing apikey) and wrong for API data,
|
|
28
|
-
// where '' is an ordinary value a server returns. A field spec therefore
|
|
29
|
-
// widens to ['`$ONE`', '`$STRING`', ['`$EXACT`', '']].
|
|
30
|
-
//
|
|
31
|
-
// OPTIONALITY. struct requires every key its spec names, so an optional field
|
|
32
|
-
// is the union of its type with `$NIL` (which matches an ABSENT value; `$NULL`
|
|
33
|
-
// matches a stored JSON null). `req: false` on a field, and `optional: true`
|
|
34
|
-
// on an opRequestShape item, both land here.
|
|
35
|
-
//
|
|
36
|
-
// WHAT THIS CANNOT EXPRESS, because the model does not carry it (the same
|
|
37
|
-
// KNOWN GAPS canonType records): array ELEMENT types, nested object schemas,
|
|
38
|
-
// enums, string formats, and any numeric or length bound. A spec built here
|
|
39
|
-
// checks the shape the model knows about and nothing more — which is why
|
|
40
|
-
// record specs are `$OPEN` (below) rather than closed.
|
|
41
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
42
3
|
exports.SPEC_STRING = void 0;
|
|
43
4
|
exports.byExampleSpec = byExampleSpec;
|
|
@@ -64,20 +25,15 @@ const S_ANY = sentinel('ANY');
|
|
|
64
25
|
const S_STRING = sentinel('STRING');
|
|
65
26
|
const S_NULL = sentinel('NULL');
|
|
66
27
|
const S_OPEN = sentinel('OPEN');
|
|
67
|
-
// Canon sentinel key -> the struct.validate sentinel that checks it.
|
|
68
|
-
// STRING is deliberately absent: it needs the empty-string widening above and
|
|
69
|
-
// is handled in canonToSpec, so a caller cannot get the bare form by accident.
|
|
70
28
|
const CANON_STRUCT = {
|
|
71
29
|
INTEGER: sentinel('INTEGER'),
|
|
72
30
|
NUMBER: sentinel('NUMBER'),
|
|
73
31
|
BOOLEAN: sentinel('BOOLEAN'),
|
|
74
32
|
NULL: sentinel('NULL'),
|
|
75
|
-
// The container renaming (difference 1 above).
|
|
76
33
|
ARRAY: sentinel('LIST'),
|
|
77
34
|
OBJECT: sentinel('MAP'),
|
|
78
35
|
ANY: S_ANY,
|
|
79
36
|
};
|
|
80
|
-
// A string that may be empty (difference 3 above).
|
|
81
37
|
const SPEC_STRING = [S_ONE, S_STRING, [S_EXACT, '']];
|
|
82
38
|
exports.SPEC_STRING = SPEC_STRING;
|
|
83
39
|
// Flatten a spec into the alternatives of a union, so that widening a value
|
|
@@ -88,29 +44,12 @@ function alternatives(spec) {
|
|
|
88
44
|
}
|
|
89
45
|
return [spec];
|
|
90
46
|
}
|
|
91
|
-
// A spec that also admits an ABSENT value.
|
|
92
|
-
//
|
|
93
|
-
// struct requires every key its spec names, so this is how "optional" is
|
|
94
|
-
// spelled. Flattened through `alternatives`, so widening something that is
|
|
95
|
-
// already a union (an empty-string-tolerant `$STRING`, an apidef `$ONE`)
|
|
96
|
-
// adds one member rather than nesting a union inside a union — which struct
|
|
97
|
-
// reads as a single alternative and rejects.
|
|
98
47
|
function optionalSpec(spec) {
|
|
99
|
-
// `$ANY` already admits an absent value, so widening it would only make
|
|
100
|
-
// the spec longer and its error messages worse.
|
|
101
48
|
if (S_ANY === spec) {
|
|
102
49
|
return spec;
|
|
103
50
|
}
|
|
104
51
|
return [S_ONE, ...alternatives(spec), S_NIL];
|
|
105
52
|
}
|
|
106
|
-
// Map one field/param type sentinel to a struct.validate spec value.
|
|
107
|
-
//
|
|
108
|
-
// Unknown or missing sentinel -> `$ANY`, never a throw: this mirrors
|
|
109
|
-
// canonToType's contract, and for the same reason. A sentinel this table has
|
|
110
|
-
// not met is a model the generator should still emit for, and an over-strict
|
|
111
|
-
// spec would reject live traffic at runtime rather than fail a build.
|
|
112
|
-
//
|
|
113
|
-
// `optional` widens the result with `$NIL` so an absent key passes.
|
|
114
53
|
function canonToSpec(type, optional) {
|
|
115
54
|
let spec;
|
|
116
55
|
if (Array.isArray(type)) {
|
|
@@ -125,27 +64,6 @@ function canonToSpec(type, optional) {
|
|
|
125
64
|
}
|
|
126
65
|
}
|
|
127
66
|
}
|
|
128
|
-
// A NULLABLE FIELD NEEDS `$NIL`, NOT JUST `$NULL`.
|
|
129
|
-
//
|
|
130
|
-
// apidef writes a nullable field as ['`$ONE`', [<type>, '`$NULL`']],
|
|
131
|
-
// and `$NULL` on its own does match a stored null. Inside a union it
|
|
132
|
-
// does not: struct resolves each alternative through a lookup that
|
|
133
|
-
// reads a stored null as "no value", so the value that reaches the
|
|
134
|
-
// `$NULL` validator is undefined and every nullable field rejected the
|
|
135
|
-
// one value it exists to allow. `$NIL` matches that no-value, so the
|
|
136
|
-
// pair covers both readings.
|
|
137
|
-
//
|
|
138
|
-
// THE COST, stated because it is real and not an oversight: `$NIL` is
|
|
139
|
-
// also how an OPTIONAL field is spelled, and struct cannot tell a
|
|
140
|
-
// stored null from an absent key inside a union — the lookup collapses
|
|
141
|
-
// them before any alternative sees the value. So a REQUIRED nullable
|
|
142
|
-
// field (`string | null`, `req: true`) also passes when the key is
|
|
143
|
-
// missing. The alternative is worse: drop `$NIL` and a nullable field
|
|
144
|
-
// rejects null, which is the one value it is declared to hold, for
|
|
145
|
-
// EVERY such field rather than weakening presence on a subset. Closing
|
|
146
|
-
// the gap needs a presence check outside struct, i.e. a second
|
|
147
|
-
// validation mechanism beside the one this whole module exists to
|
|
148
|
-
// reuse. Revisit if struct gains a spelling that separates them.
|
|
149
67
|
if (0 <= members.indexOf(S_NULL) && members.indexOf(S_NIL) < 0) {
|
|
150
68
|
members.push(S_NIL);
|
|
151
69
|
}
|
|
@@ -163,14 +81,6 @@ function canonToSpec(type, optional) {
|
|
|
163
81
|
}
|
|
164
82
|
return optional ? optionalSpec(spec) : spec;
|
|
165
83
|
}
|
|
166
|
-
// The spec for one entity RECORD: every active field, keyed by name.
|
|
167
|
-
//
|
|
168
|
-
// OPEN, ALWAYS. apidef records the properties a spec declared, which is not a
|
|
169
|
-
// promise that a response carries nothing else — a server that adds a field is
|
|
170
|
-
// not breaking its clients, and a closed spec would turn that into a client
|
|
171
|
-
// error for every caller at once. The declared fields are type-checked; the
|
|
172
|
-
// rest pass. A caller who wants the closed reading drops `$OPEN` at runtime
|
|
173
|
-
// (the validate feature's `strict` option does exactly that).
|
|
174
84
|
function entityDataSpec(ent) {
|
|
175
85
|
const spec = { [S_OPEN]: true };
|
|
176
86
|
const fields = (ent && ent.fields) ? (0, jostraca_1.each)(ent.fields) : [];
|
|
@@ -182,12 +92,6 @@ function entityDataSpec(ent) {
|
|
|
182
92
|
}
|
|
183
93
|
return spec;
|
|
184
94
|
}
|
|
185
|
-
// The spec for one operation's REQUEST payload.
|
|
186
|
-
//
|
|
187
|
-
// The members and their optionality are opRequestShape's answer, not a second
|
|
188
|
-
// reading of the model: the partiality policy that decides what a generated
|
|
189
|
-
// `<Name>CreateData` requires is the same policy that decides what a create
|
|
190
|
-
// call must carry, and two copies of it would drift the moment one is edited.
|
|
191
95
|
function entityOpSpec(ent, opname) {
|
|
192
96
|
const { items } = (0, opShape_1.opRequestShape)(ent, opname);
|
|
193
97
|
if (0 === items.length) {
|
|
@@ -214,24 +118,6 @@ function entitySpecs(ent) {
|
|
|
214
118
|
}
|
|
215
119
|
return { data: entityDataSpec(ent), op };
|
|
216
120
|
}
|
|
217
|
-
// A DEFAULT VALUE, read as a type.
|
|
218
|
-
//
|
|
219
|
-
// A feature declares its options as defaults (`ttl: 5000`, `currency: 'USD'`,
|
|
220
|
-
// `methods: ['GET']`) — a map written to document what happens when you say
|
|
221
|
-
// nothing, not to state a type. struct.validate reads it by example, and by
|
|
222
|
-
// example is SHARPER than the author meant: `unit: 0` says "an integer", so
|
|
223
|
-
// cost's own `unit: 0.002` failed its own feature's spec; `header: ''` says
|
|
224
|
-
// "a non-empty string", which the default itself is not.
|
|
225
|
-
//
|
|
226
|
-
// So the default is kept for its KIND and widened to that kind's sentinel.
|
|
227
|
-
// Nothing is lost by dropping the value: a feature's defaults are applied by
|
|
228
|
-
// the feature's own code (`this._options.currency || 'USD'`), never by this
|
|
229
|
-
// spec — each feature entry is optional, and struct fills in nothing through
|
|
230
|
-
// an optional union.
|
|
231
|
-
//
|
|
232
|
-
// This applies to a DEFAULTS map only. `main.kit.optspec` is written as a
|
|
233
|
-
// spec, so its concrete values are the author's own choice of constraint and
|
|
234
|
-
// are passed through untouched.
|
|
235
121
|
function byExampleSpec(val) {
|
|
236
122
|
if (null == val) {
|
|
237
123
|
return S_ANY;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"canonSpec.js","sourceRoot":"","sources":["../../src/helpers/canonSpec.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"canonSpec.js","sourceRoot":"","sources":["../../src/helpers/canonSpec.ts"],"names":[],"mappings":";;;QAkLE,aAAa;QACb,WAAW;QACX,YAAY;QACZ,cAAc;QACd,YAAY;QACZ,WAAW;QACX,QAAQ;AAvLV,uCAA+B;AAE/B,2CAAsC;AACtC,uCAA0C;AAG1C,0EAA0E;AAC1E,4EAA4E;AAC5E,+CAA+C;AAC/C,MAAM,EAAE,GAAG,MAAM,CAAC,YAAY,CAAC,EAAE,CAAC,CAAA;AAElC,SAAS,QAAQ,CAAC,IAAY;IAC5B,OAAO,EAAE,GAAG,GAAG,GAAG,IAAI,GAAG,EAAE,CAAA;AAC7B,CAAC;AAGD,MAAM,KAAK,GAAG,QAAQ,CAAC,KAAK,CAAC,CAAA;AAC7B,MAAM,OAAO,GAAG,QAAQ,CAAC,OAAO,CAAC,CAAA;AACjC,MAAM,KAAK,GAAG,QAAQ,CAAC,KAAK,CAAC,CAAA;AAC7B,MAAM,KAAK,GA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AQ,CAAC,KAAK,CAAC,CAAA;AACxB,CAAC"}
|
|
@@ -1,52 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
// Canonical type-sentinel -> language primitive type mapper.
|
|
3
|
-
//
|
|
4
|
-
// SOURCE OF TRUTH for the sentinel set: @voxgig/apidef (`VALID_CANON` +
|
|
5
|
-
// `CANON_ONE`, exported from the package). VALID_CANON maps an OpenAPI type
|
|
6
|
-
// NAME -> a `$SENTINEL` string (e.g. 'string' -> `$STRING`). The model stores
|
|
7
|
-
// those sentinels on every `fields[].type` and op `points[].args.params[].type`.
|
|
8
|
-
// A multi-type (OpenAPI `type: [a, b]`) is stored as the ARRAY-shaped union
|
|
9
|
-
// sentinel `['`$ONE`', [member, ...]]` (see canonToType below).
|
|
10
|
-
//
|
|
11
|
-
// This table maps the SENTINEL the other way -> a concrete primitive type in
|
|
12
|
-
// each target language, so the typed-model generators (EntityTypes_<lang>.ts)
|
|
13
|
-
// and the README type columns (ReadmeRef_<lang>.ts / ReadmeEntity_<lang>.ts)
|
|
14
|
-
// can turn the model's field/param sentinels into real language types. It is
|
|
15
|
-
// the SINGLE mapping per language: components must not keep local copies.
|
|
16
|
-
//
|
|
17
|
-
// Kept as a small mirror here (rather than importing VALID_CANON at runtime)
|
|
18
|
-
// because apidef is a peer dependency and the table is the INVERSE direction.
|
|
19
|
-
//
|
|
20
|
-
// `ts/test/canonsync.test.ts` guards it two ways: the vocabulary and every
|
|
21
|
-
// language column are pinned LOCALLY (that check always runs), and the table
|
|
22
|
-
// is cross-checked against apidef's exported VALID_CANON/CANON_ONE when the
|
|
23
|
-
// installed apidef exports them. Note that the currently published apidef
|
|
24
|
-
// (6.3.1) does NOT export them, so the cross-check skips — do not rely on it
|
|
25
|
-
// alone; add a new sentinel to the local list in the same change.
|
|
26
|
-
//
|
|
27
|
-
// KNOWN GAPS (papered over sanely, documented for the port):
|
|
28
|
-
// - Unknown / missing sentinel -> the language's "any" (never throws).
|
|
29
|
-
// - Array element typing is not in the model: $ARRAY maps to an untyped
|
|
30
|
-
// list/array. `list` ops return T[] via op-kind inference in the op
|
|
31
|
-
// fragment, NOT via a field sentinel.
|
|
32
|
-
// - Object/nested field schemas are not in the corpus: $OBJECT maps to the
|
|
33
|
-
// language's open record/map type.
|
|
34
|
-
// - No enum/format/nullability beyond the `req` flag.
|
|
35
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
3
|
exports.PANDAS_DTYPE = exports.CANON_UNION_JOIN = exports.CANON_ANY = exports.CANON_TYPE = void 0;
|
|
37
4
|
exports.canonToType = canonToType;
|
|
38
5
|
exports.canonToDtype = canonToDtype;
|
|
39
6
|
exports.canonKey = canonKey;
|
|
40
7
|
exports.canonScalarKey = canonScalarKey;
|
|
41
|
-
// Bare sentinel key (backticks + leading `$` stripped, upper-cased)
|
|
42
|
-
// -> per-language primitive type name.
|
|
43
|
-
//
|
|
44
|
-
// Column notes:
|
|
45
|
-
// - kotlin: every type is nullable (`?`) — the kotlin emitter drops
|
|
46
|
-
// per-member optionality because the column is already-nullable.
|
|
47
|
-
// - java/scala: boxed JVM types (nullable), so optionality needs no marker.
|
|
48
|
-
// - rust/c/cpp/swift: `Value`/`voxgig_value*`/`VMap` are the vendored
|
|
49
|
-
// dynamic value types those runtimes ship.
|
|
50
8
|
const CANON_TYPE = {
|
|
51
9
|
STRING: {
|
|
52
10
|
ts: 'string', js: 'string', py: 'str', php: 'string', rb: 'String',
|
|
@@ -111,11 +69,6 @@ const CANON_ANY = {
|
|
|
111
69
|
rust: 'Value', c: 'voxgig_value*', cpp: 'Value', elixir: 'any()',
|
|
112
70
|
};
|
|
113
71
|
exports.CANON_ANY = CANON_ANY;
|
|
114
|
-
// Union ($ONE) member separator for languages with a native union/sum type
|
|
115
|
-
// syntax. Languages absent here have no way to express an anonymous union in
|
|
116
|
-
// a type position, so a $ONE sentinel degrades to that language's "any".
|
|
117
|
-
// (php 8 unions exist but cannot combine with the `?` optional prefix the
|
|
118
|
-
// emitters use, so php deliberately degrades to `mixed`.)
|
|
119
72
|
const CANON_UNION_JOIN = {
|
|
120
73
|
ts: ' | ',
|
|
121
74
|
js: '|',
|
|
@@ -124,23 +77,6 @@ const CANON_UNION_JOIN = {
|
|
|
124
77
|
elixir: ' | ',
|
|
125
78
|
};
|
|
126
79
|
exports.CANON_UNION_JOIN = CANON_UNION_JOIN;
|
|
127
|
-
// Canonical sentinel -> pandas dtype, for the `py-data` target's generated
|
|
128
|
-
// DataFrame accessors. Deliberately NOT a CanonLang column: py-data is a
|
|
129
|
-
// consumer target layered on `py`, not a language, and these are storage
|
|
130
|
-
// dtypes rather than type-annotation names.
|
|
131
|
-
//
|
|
132
|
-
// NULLABLE dtypes throughout ('Int64' not 'int64', 'boolean' not 'bool').
|
|
133
|
-
// The model carries no nullability beyond the `req` flag, and API payloads
|
|
134
|
-
// omit optional fields freely, so a column that looks integral in one page
|
|
135
|
-
// can arrive with nulls in the next. NumPy's int64/bool cannot hold NA and
|
|
136
|
-
// would silently upcast to float64/object mid-fetch, changing a column's
|
|
137
|
-
// dtype based on which rows came back — the pandas nullable extension types
|
|
138
|
-
// keep it stable.
|
|
139
|
-
//
|
|
140
|
-
// There is no $DATE / $DATETIME sentinel in apidef's vocabulary (the model
|
|
141
|
-
// carries no string formats), so date handling is NOT inferred here. It is
|
|
142
|
-
// an explicit runtime opt-in via the accessor's `parse_dates=` kwarg. Do not
|
|
143
|
-
// add a DATE row unless apidef starts emitting the sentinel.
|
|
144
80
|
const PANDAS_DTYPE = {
|
|
145
81
|
STRING: 'string',
|
|
146
82
|
INTEGER: 'Int64',
|
|
@@ -174,21 +110,6 @@ function canonKey(sentinel) {
|
|
|
174
110
|
}
|
|
175
111
|
return String(sentinel).replace(/[`$]/g, '').trim().toUpperCase();
|
|
176
112
|
}
|
|
177
|
-
// The bare key of the sentinel a VALUE of this type must satisfy, resolving
|
|
178
|
-
// the union sentinel `['`$ONE`', [member, ...]]` to its first non-NULL member
|
|
179
|
-
// (recursively — a member may itself be a union).
|
|
180
|
-
//
|
|
181
|
-
// canonKey alone cannot do this: given an array it stringifies it, so a
|
|
182
|
-
// nullable `['`$ONE`', ['`$NUMBER`','`$NULL`']]` field yields neither NUMBER
|
|
183
|
-
// nor anything else recognizable and every caller falls through to its
|
|
184
|
-
// "unknown, use a string" branch. canonToType meanwhile renders that same
|
|
185
|
-
// sentinel as `number | null`, so the doc example said `'..._id'` while the
|
|
186
|
-
// generated type said `number` — a TS2322 in the SDK's own README, which is
|
|
187
|
-
// exactly the disagreement the example helpers exist to prevent.
|
|
188
|
-
//
|
|
189
|
-
// A union of nothing but NULL resolves to NULL; an unrecognized array shape,
|
|
190
|
-
// or an empty member list, resolves to '' (unknown) like any missing
|
|
191
|
-
// sentinel.
|
|
192
113
|
function canonScalarKey(sentinel) {
|
|
193
114
|
if (Array.isArray(sentinel)) {
|
|
194
115
|
if ('ONE' !== canonKey(sentinel[0]) || !Array.isArray(sentinel[1])) {
|
|
@@ -209,14 +130,6 @@ function canonScalarKey(sentinel) {
|
|
|
209
130
|
}
|
|
210
131
|
return canonKey(sentinel);
|
|
211
132
|
}
|
|
212
|
-
// Map a field/param type sentinel to a target-language primitive type.
|
|
213
|
-
// Unknown or missing sentinel -> that language's "any" (never throws).
|
|
214
|
-
//
|
|
215
|
-
// The union sentinel `['`$ONE`', [member, ...]]` (apidef CANON_ONE, produced
|
|
216
|
-
// for OpenAPI multi-types) renders as a joined member union in languages with
|
|
217
|
-
// union syntax (see CANON_UNION_JOIN); elsewhere it degrades to "any".
|
|
218
|
-
// Members may themselves be unions (handled recursively) or the literal
|
|
219
|
-
// 'Any' apidef emits for an unknown member name (canonKey maps it to ANY).
|
|
220
133
|
function canonToType(sentinel, lang) {
|
|
221
134
|
const l = lang;
|
|
222
135
|
const fallback = CANON_ANY[l] ?? 'any';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"canonType.js","sourceRoot":"","sources":["../../src/helpers/canonType.ts"],"names":[],"mappings":"
|
|
1
|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AI,KAAK,CAAC,OAAO,CAAC,QAAQ,CAAC,EAAE,CAAC;QAC5B,IAAI,KAAK,KAAK,QAAQ,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,IAAI,KAAK,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;YAClE,MAAM,IAAI,GAAG,gBAAgB,CAAC,CAAC,CAAC,CAAA;YAChC,IAAI,IAAI,IAAI,IAAI,EAAE,CAAC;gBACjB,OAAO,QAAQ,CAAA;YACjB,CAAC;YACD,MAAM,OAAO,GAAG,QAAQ,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAU,EAAE,EAAE,CAAC,WAAW,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAA;YAClE,MAAM,IAAI,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC,CAAS,EAAE,CAAS,EAAE,EAAE,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAA;YAC/E,OAAO,CAAC,KAAK,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,CAAA;QACvD,CAAC;QACD,OAAO,QAAQ,CAAA;IACjB,CAAC;IAED,MAAM,GAAG,GAAG,UAAU,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC,CAAA;IAC1C,IAAI,IAAI,IAAI,GAAG,EAAE,CAAC;QAChB,OAAO,QAAQ,CAAA;IACjB,CAAC;IAED,OAAO,GAAG,CAAC,CAAC,CAAC,IAAI,QAAQ,CAAA;AAC3B,CAAC"}
|
|
@@ -1,25 +1,4 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
// Collect target-language dependencies from features and from the target's
|
|
3
|
-
// own `deps` block, applying the active-flag semantics that every Package_*.ts
|
|
4
|
-
// template was hand-rolling identically:
|
|
5
|
-
//
|
|
6
|
-
// - feature deps : included when `dep.active === true` (default off)
|
|
7
|
-
// - plugin deps : the same, and only for an ACTIVE plugin of that feature
|
|
8
|
-
// - target deps : included when `dep.active !== false` (default on)
|
|
9
|
-
//
|
|
10
|
-
// THE PLUGIN LEVEL IS GATED ONE STEP DEEPER THAN THE FEATURE. A feature's
|
|
11
|
-
// deps flow as soon as the feature is active; a plugin is a trimmable part
|
|
12
|
-
// within an active feature, so a dependency only its files use must not
|
|
13
|
-
// reach the manifest until that plugin is active too. rust's mini vault is
|
|
14
|
-
// the case: it takes `ring` for AES-256-GCM, and at feature level that
|
|
15
|
-
// would land in every secrets-enabled rust SDK, including the ones whose
|
|
16
|
-
// chain is `[env, dotenv]` and which never compile a vault.
|
|
17
|
-
//
|
|
18
|
-
// The two sources are kept distinct via the `source` field so callers can
|
|
19
|
-
// apply their own version defaults / formatting (e.g. go uses `v0.0.0`,
|
|
20
|
-
// python `0.0`). The original dep object is exposed as `raw` for callers that
|
|
21
|
-
// need extra fields like `dep.replace` (go module replace directives) or
|
|
22
|
-
// `dep.kind` (prod/dev/peer).
|
|
23
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
24
3
|
exports.collectDeps = collectDeps;
|
|
25
4
|
const applicability_1 = require("./applicability");
|
|
@@ -29,12 +8,6 @@ function collectDeps(model, targetName, targetDeps, log) {
|
|
|
29
8
|
// Gated: a feature that does not apply to this target must not flow a
|
|
30
9
|
// dependency into its generated manifest.
|
|
31
10
|
const feature = (0, applicability_1.targetFeatures)(model, targetName);
|
|
32
|
-
// Deduplicate by package name. Two features can require the same package
|
|
33
|
-
// (or a feature and the target itself can), and every Package_<lang>.ts
|
|
34
|
-
// renders one manifest line per entry — a duplicate key is a hard parse
|
|
35
|
-
// error in go.mod and Cargo.toml, and silently last-wins in package.json.
|
|
36
|
-
// FIRST occurrence wins, so the deterministic (sorted-key) feature order
|
|
37
|
-
// decides; a conflicting version is reported rather than silently dropped.
|
|
38
11
|
const seen = {};
|
|
39
12
|
const add = (dep, source, owner) => {
|
|
40
13
|
const name = dep.key$;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"collectDeps.js","sourceRoot":"","sources":["../../src/helpers/collectDeps.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"collectDeps.js","sourceRoot":"","sources":["../../src/helpers/collectDeps.ts"],"names":[],"mappings":";;QAmGE,WAAW;AAlGb,mDAAgD;AAEhD,uCAA+B;AAY/B,SAAS,WAAW,CAClB,KAAe,EACf,UAAkB,EAClB,UAAgD,EAChD,GAAS;IAET,MAAM,GAAG,GAAe,EAAE,CAAA;IAC1B,sEAAsE;IACtE,0CAA0C;IAC1C,MAAM,OAAO,GAAG,IAAA,8BAAc,EAAC,KAAK,EAAE,UAAU,CAAC,CAAA;IAEjD,MAAM,IAAI,GAA6B,EAAE,CAAA;IAEzC,MAAM,GAAG,GAAG,CAAC,GAAQ,EAAE,MAA4B,EAAE,KAAa,EAAE,EAAE;QACpE,MAAM,IAAI,GAAG,GAAG,CAAC,IAAI,CAAA;QACrB,IAAI,IAAI,IAAI,IAAI;YAAE,OAAM;QAExB,MAAM,IAAI,GAAG,IAAI,CAAC,IAAI,CAAC,CAAA;QACvB,IAAI,IAAI,IAAI,IAAI,EAAE,CAAC;YACjB,IAAI,GAAG,EAAE,IAAI,IAAI,IAAI,CAAC,OAAO,KAAK,GAAG,CAAC,OAAO,EAAE,CAAC;gBAC9C,GAAG,CAAC,IAAI,CAAC;oBACP,KAAK,EAAE,sBAAsB,EAAE,MAAM,EAAE,UAAU,EAAE,GAAG,EAAE,IAAI;oBAC5D,IAAI,EAAE,IAAI,CAAC,OAAO,EAAE,OAAO,EAAE,GAAG,CAAC,OAAO,EAAE,IAAI,EAAE,KAAK;oBACrD,IAAI,EAAE,GAAG,UAAU,gBAAgB,IAAI,uBAAuB;wBAC5D,gCAAgC,IAAI,CAAC,OAAO,KAAK,IAAI,CAAC,MAAM,KAAK;wBACjE,YAAY,GAAG,CAAC,OAAO,KAAK,MAAM,IAAI,KAAK,GAAG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AC,CAAC,CAAA;IACJ,CAAC,CAAC,CAAA;IAEF,IAAI,UAAU,EAAE,CAAC;QACf,IAAA,eAAI,EAAC,UAAU,EAAE,CAAC,GAAQ,EAAE,EAAE;YAC5B,IAAI,GAAG,EAAE,MAAM,KAAK,KAAK,EAAE,CAAC;gBAC1B,GAAG,CAAC,GAAG,EAAE,QAAQ,EAAE,UAAU,CAAC,CAAA;YAChC,CAAC;QACH,CAAC,CAAC,CAAA;IACJ,CAAC;IAED,OAAO,GAAG,CAAA;AACZ,CAAC"}
|
|
@@ -1,19 +1,4 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
// WHERE A KIND'S DEFINITION FILES LIVE.
|
|
3
|
-
//
|
|
4
|
-
// `model/<kind>/<name>.aon`, with `model/<kind>/<kind>-index.aon` as the
|
|
5
|
-
// include list beside them. One line of path-building — and it was written out
|
|
6
|
-
// longhand in three places (the resolver, the feature catalogue, doctor), each
|
|
7
|
-
// with its own idea of which files in that directory count.
|
|
8
|
-
//
|
|
9
|
-
// That is the same shape of defect this workstream has now fixed four times:
|
|
10
|
-
// the same rule expressed twice, drifting. The manifest makes it four callers,
|
|
11
|
-
// so it becomes one function first.
|
|
12
|
-
//
|
|
13
|
-
// The EXCLUSIONS matter as much as the path. A `model/<kind>/` directory holds
|
|
14
|
-
// the index file (a list of includes, not a definition) and, in the shipped
|
|
15
|
-
// scaffold, a `README.md`. Neither is an item, and a caller that forgets one
|
|
16
|
-
// invents a `feature-index` feature.
|
|
17
2
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
18
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
19
4
|
};
|
|
@@ -36,23 +21,9 @@ function definitionFolder(sdkfolder, kind) {
|
|
|
36
21
|
function indexName(kind) {
|
|
37
22
|
return kind + '-index.aon';
|
|
38
23
|
}
|
|
39
|
-
// Every item of `kind` a `.sdk` folder DEFINES, sorted. Sorted because it
|
|
40
|
-
// feeds an exact-set comparison against a manifest and, through
|
|
41
|
-
// `availableFeatures`, the feature-trim catalogue — both of which are compared
|
|
42
|
-
// as text, so a readdir order that varies by filesystem would vary the result.
|
|
43
|
-
//
|
|
44
|
-
// An absent directory is not an error: a package providing only features has
|
|
45
|
-
// no `model/target/`, and that is the normal shape of a feature package.
|
|
46
24
|
function definitionNames(fs, sdkfolder, kind) {
|
|
47
25
|
const dir = definitionFolder(sdkfolder, kind);
|
|
48
26
|
const index = indexName(kind);
|
|
49
|
-
// `existsSync` is true for a REGULAR FILE and for a directory this process
|
|
50
|
-
// cannot read, so guarding on it and then calling `readdirSync` let a bare
|
|
51
|
-
// `ENOTDIR`/`EACCES` escape to callers that have no catch — including
|
|
52
|
-
// `featureCatalogue`, which runs on every ordinary `target add`, so the
|
|
53
|
-
// whole add aborted with an errno instead of a diagnostic. Not-a-readable-
|
|
54
|
-
// directory is the same answer as not-there: this kind defines nothing
|
|
55
|
-
// here.
|
|
56
27
|
let entries;
|
|
57
28
|
try {
|
|
58
29
|
entries = fs.readdirSync(dir);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"definition.js","sourceRoot":"","sources":["../../src/helpers/definition.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"definition.js","sourceRoot":"","sources":["../../src/helpers/definition.ts"],"names":[],"mappings":";;;;;QAgDE,cAAc;QACd,gBAAgB;QAChB,eAAe;QACf,SAAS;AAlDX,0DAA4B;AAE5B,iCAA+B;AAG/B,oCAAoC;AACpC,SAAS,cAAc,CAAC,SAAiB,EAAE,IAAY,EAAE,IAAY;IACnE,OAAO,mBAAI,CAAC,IAAI,CAAC,SAAS,EAAE,OAAO,EAAE,IAAI,EAAE,IAAI,GAAG,MAAM,CAAC,CAAA;AAC3D,CAAC;AAGD,8CAA8C;AAC9C,SAAS,gBAAgB,CAAC,SAAiB,EAAE,IAAY;IACvD,OAAO,mBAAI,CAAC,IAAI,CAAC,SAAS,EAAE,OAAO,EAAE,IAAI,CAAC,CAAA;AAC5C,CAAC;AAGD,gCAAgC;AAChC,SAAS,SAAS,CAAC,IAAY;IAC7B,OAAO,IAAI,GAAG,YAAY,CAAA;AAC5B,CAAC;AAGD,SAAS,eAAe,CAAC,EAAO,EAAE,SAAiB,EAAE,IAAY;IAC/D,MAAM,GAAG,GAAG,gBAAgB,CAAC,SAAS,EAAE,IAAI,CAAC,CAAA;IAC7C,MAAM,KAAK,GAAG,SAAS,CAAC,IAAI,CAAC,CAAA;IAE7B,IAAI,OAAiB,CAAA;IACrB,IAAI,CAAC;QACH,OAAO,GAAG,EAAE,CAAC,WAAW,CAAC,GAAG,CAAC,CAAA;IAC/B,CAAC;IACD,OAAO,GAAQ,EAAE,CAAC;QAChB,OAAO,EAAE,CAAA;IACX,CAAC;IAED,0EAA0E;IAC1E,yEAAyE;IACzE,6EAA6E;IAC7E,oDAAoD;IACpD,OAAO,OAAO;SACX,MAAM,CAAC,CAAC,CAAS,EAAE,EAAE,CAAC,CAAC,CAAC,QAAQ,CAAC,MAAM,CAAC,IAAI,KAAK,KAAK,CAAC,IAAI,CAAC,IAAA,aAAM,EAAC,CAAC,CAAC,CAAC;SACtE,GAAG,CAAC,CAAC,CAAS,EAAE,EAAE,CAAC,CAAC,CAAC,OAAO,CAAC,QAAQ,EAAE,EAAE,CAAC,CAAC;SAC3C,IAAI,EAAE,CAAA;AACX,CAAC"}
|
package/dist/helpers/dryrun.js
CHANGED
|
@@ -1,12 +1,4 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
// Report what a dry run WOULD have done.
|
|
3
|
-
//
|
|
4
|
-
// `@voxgig/util`'s showChanges only lists merged and conflicted files, which
|
|
5
|
-
// on a fresh `target add` is nothing at all — so `-y target add ts` printed
|
|
6
|
-
// `** DRY RUN **`, listed no files, and (before the control fix) wrote them
|
|
7
|
-
// anyway. A preview that shows nothing is indistinguishable from a preview of
|
|
8
|
-
// nothing, which is exactly the wrong answer for the command whose whole job
|
|
9
|
-
// is to overwrite a project's vendored scaffold.
|
|
10
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
11
3
|
exports.showDryrun = showDryrun;
|
|
12
4
|
// Log every path the run touched, one line each, plus a total. `written`
|