Documentation
¶
Overview ¶
Package generatepackages is the importable form of the charly COMMAND-class plugin contributing `charly generate-packages`, usable in BOTH placements (F8): COMPILED INTO charly in-process (charly imports this package + registers NewProvider()/ NewMeta() via plugins_generated.go; `charly generate-packages <args>` dispatches IN-PROC via Invoke(OpRun) — dispatchInProcCommand) OR served OUT-OF-PROCESS (the cmd/serve shim; charly fork/execs the binary in CLI mode → CliMain). Both placements run the SAME effect (build the requested native packages via sdk/packagekit), so the command behaves identically regardless of placement — the placement-invisible command, the command-class analogue of candy/plugin-example-external. The dynamic Kong grammar (pass-through Args) is built host-side (externalCommandHolder) for both placements; only the dispatch transport differs.
The plugin is the command surface ONLY: every nFPM/parsing/variant/optdepends function lives in sdk/packagekit (shared with the sdk's localpkg replacement). The plugin reads the `packaging:` section from the charly.yml named by --candy and builds the packages from that + the flags — no deps table, no other metadata resource.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CliMain ¶
CliMain is the OUT-OF-PROCESS CLI-mode entry (charly fork/execs the binary with the pass-through tokens after `charly generate-packages`). It runs the SAME effect as the in-proc Invoke(OpRun) path.
func NewMeta ¶
func NewMeta() pb.PluginMetaServer
NewMeta advertises command:generate-packages via sdk.NewMeta → BuildCapabilities so the COMPILED-IN path registers it as a command provider (buildUnitInProc → inprocProvider Class=command; the host builds its dynamic Kong grammar + dispatches Invoke(OpRun)). The served schema carries no #*Input def — a command's args are pass-through CLI tokens, not a structured plugin_input — so the capability has no InputDef.
func NewProvider ¶
func NewProvider() pb.ProviderServer
NewProvider returns the command provider for in-proc registration (compiled-in) or out-of-proc serving.
Types ¶
This section is empty.