Skip to content

[KZN-17594] - Scaffolding Improvements - #20

Merged
keegandonley merged 4 commits into
mainfrom
feature/KZN-17594-scaffold-command
Sep 4, 2026
Merged

[KZN-17594] - Scaffolding Improvements#20
keegandonley merged 4 commits into
mainfrom
feature/KZN-17594-scaffold-command

Conversation

@keegandonley

Copy link
Copy Markdown
Member

This PR updates the scaffolding command via create so that it creates something buildable out of the box, and so that the scaffolded plugin is actually useful in its initial state.

CopilotAI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Improves create so generated plugins are buildable, publish-ready, and usable in interactive or headless workflows.

Changes:

  • Adds headless flags and interactive artifact selection.
  • Scaffolds starter artifacts, a thumbnail, and Copilot guidance.
  • Adds raw-template bundling and expanded validation tests.

Reviewed changes

Copilot reviewed 41 out of 42 changed files in this pull request and generated 5 comments.

Show a summary per file
FileDescription
vitest.config.tsEnables raw CSS template imports.
tsup.config.tsAdds raw-file bundling support.
src/ui/CreateUI.tsxAdds artifact selection and environment-aware creation.
src/templates/github/instructions/version-discipline.instructions.mdAdds manifest version guidance.
src/templates/github/instructions/security.instructions.mdAdds generated security guidance.
src/templates/github/copilot-instructions.mdAdds generated repository guidance.
src/templates/artifacts/toolbarItems/helloToolbarItem/script.jsAdds toolbar behavior.
src/templates/artifacts/toolbarItems/helloToolbarItem/config.jsonConfigures the toolbar item.
src/templates/artifacts/pages/helloPage/styles.cssStyles the starter page.
src/templates/artifacts/pages/helloPage/script.jsAdds page initialization.
src/templates/artifacts/pages/helloPage/eventScripts/greet.jsAdds page interactions.
src/templates/artifacts/pages/helloPage/config.jsonConfigures the starter page.
src/templates/artifacts/objectSettingsItems/helloObjectSettingsItem/script.jsAdds settings-item behavior.
src/templates/artifacts/objectSettingsItems/helloObjectSettingsItem/config.jsonConfigures the settings item.
src/templates/artifacts/floatingFrames/helloFrame/styles.cssStyles the starter frame.
src/templates/artifacts/floatingFrames/helloFrame/script.jsAdds frame UI.
src/templates/artifacts/floatingFrames/helloFrame/config.jsonConfigures the starter frame.
src/templates/artifacts/dataAdornments/helloAdornment/script.jsAdds adornment behavior.
src/templates/artifacts/dataAdornments/helloAdornment/config.jsonConfigures the adornment.
src/templates/artifacts/blocks/helloBlock/styles.cssStyles the starter block.
src/templates/artifacts/blocks/helloBlock/script.jsAdds block UI.
src/templates/artifacts/blocks/helloBlock/config.jsonConfigures the starter block.
src/templates/artifacts/actions/helloAction/script.jsAdds action behavior.
src/templates/artifacts/actions/helloAction/config.jsonConfigures the starter action.
src/program.test.tsVerifies new create flags.
src/lib/runBuild.test.tsTests complete scaffold packaging.
src/lib/createThumbnail.tsGenerates placeholder PNG thumbnails.
src/lib/createThumbnail.test.tsValidates PNG generation.
src/lib/createPlugin.tsWrites expanded scaffold contents.
src/lib/createPlugin.test.tsTests manifests and generated files.
src/lib/createHeadless.tsImplements non-interactive creation.
src/lib/createHeadless.test.tsTests headless behavior.
src/lib/createForm.tsAdds required descriptions and artifact toggling.
src/lib/createForm.test.tsTests updated form helpers.
src/lib/createCopilotFiles.tsMaps Copilot templates into scaffolds.
src/lib/createArtifacts.tsDefines scaffoldable artifacts.
src/lib/createArtifacts.test.tsValidates artifact file generation.
src/commands/create.tsWires flags and headless execution.
src/assets.d.tsTypes raw imports.
src/__snapshots__/program.test.ts.snapUpdates CLI help snapshot.
eslint.config.mjsExcludes runtime templates from linting.
.prettierignorePreserves authored template Markdown.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

.option('-a, --api-name <name>', 'plugin api_name (inferred from --name when omitted)')
.option('-d, --description <text>', 'plugin description')
.option('-l, --external-link <url>', 'external link shown on the plugin listing')
.option('-b, --business-id <id>', 'developer business id (defaults to saved credentials)')
Comment threadsrc/lib/createForm.ts
};

export const REQUIRED_FIELDS: readonly FieldName[] = ['name', 'apiName'];
export const REQUIRED_FIELDS: readonly FieldName[] = ['name', 'apiName', 'description'];
Comment threadsrc/lib/createPlugin.ts Outdated
Comment on lines +32 to +36
/**
* Artifact types to scaffold under `src/`. An empty list (the default)
* reproduces the old behaviour of an empty `src/`, which builds to a plugin
* with no artifacts at all.
*/
@@ -0,0 +1,64 @@
---
applyTo: "src/**/*.js"
Comment threadsrc/ui/CreateUI.tsx Outdated
<Box flexDirection="column" gap={0}>
<Text bold>Artifacts</Text>
{phase.artifacts.length === 0 ? (
<Text dimColor>{' '}none — src/ will be empty</Text>

@mauricebecnel400mauricebecnel400 left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@keegandonley
keegandonley merged commit a7e2e79 into mainSep 4, 2026
4 checks passed
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

@keegandonley@mauricebecnel400