meshery/meshery
在 GitHub 查看[mesheryctl] Populate generated model definitions with the requested model name
Open
#18,982 创建于 2026年4月29日
help wanted
描述
See mesheryctl Command Tracker for current status of commands.
Current Behavior
mesheryctl model init scaffolds the directory structure, but it leaves a TODO in code for inserting the requested model name into the generated model definition.
As a result, users still have to perform an immediate manual edit in the primary generated file before the scaffold feels complete.
Desired Behavior
The generated model.json / model.yaml should already contain the requested model name so that the scaffold is closer to being ready-to-edit out of the box.
Implementation
Relevant code path:
mesheryctl/internal/cli/root/model/init.go- trailing TODO:
put a model name into generated model file
Acceptance Tests
- Running
mesheryctl model init my-modelshould emit a generated model definition whose name field is alreadymy-model. - Both JSON and YAML outputs should receive the requested name.
- Existing scaffold generation tests should cover the populated name field.
Mockups
N/A