Skip to content

feat(extension): add elastic extension command group (list, install, remove)#302

Open
margaretjgu wants to merge 2 commits into
feat/extension-installerfrom
feat/extension-commands
Open

feat(extension): add elastic extension command group (list, install, remove)#302
margaretjgu wants to merge 2 commits into
feat/extension-installerfrom
feat/extension-commands

Conversation

@margaretjgu
Copy link
Copy Markdown
Member

Summary

Closes #296. Part of #222. Depends on #301.

  • Adds src/extension/register.ts with registerExtensionCommands() building the elastic extension group
  • Three subcommands: list, install <source>, remove <name>
  • Extension commands bypass config loading (no Elastic cluster needed); handled by skipping the preAction hook for any command whose ancestor is extension
  • cli.ts: lazy-loads registerExtensionCommands() when firstArg === 'extension'; excludes extension from the early config load path alongside config, sanitize, and version

Test plan

  • npx tsc --noEmit passes clean
  • elastic extension --help shows list/install/remove subcommands
  • elastic extension list returns [] with no extensions installed
  • elastic extension install github:elastic/elastic-local (functional, requires network)
  • elastic extension remove local after install

@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 12, 2026

MegaLinter analysis: Success

Descriptor Linter Files Fixed Errors Warnings Elapsed time
✅ COPYPASTE jscpd yes no no 6.4s
✅ REPOSITORY gitleaks yes no no 91.74s
✅ REPOSITORY git_diff yes no no 0.47s
✅ REPOSITORY secretlint yes no no 22.78s
✅ REPOSITORY trivy yes no no 16.2s
✅ TYPESCRIPT eslint 6 0 0 3.39s

See detailed reports in MegaLinter artifacts
Set VALIDATE_ALL_CODEBASE: true in mega-linter.yml to validate all sources, not only the diff

MegaLinter is graciously provided by OX Security
Show us your support by starring ⭐ the repository

@margaretjgu margaretjgu force-pushed the feat/extension-installer branch from 19fd55e to 850c2ac Compare May 12, 2026 16:49
@margaretjgu margaretjgu force-pushed the feat/extension-commands branch from 449c3a8 to 3773081 Compare May 12, 2026 16:49
@margaretjgu margaretjgu force-pushed the feat/extension-installer branch from 850c2ac to 2346150 Compare May 12, 2026 16:59
@margaretjgu margaretjgu force-pushed the feat/extension-commands branch from 3773081 to 9958a96 Compare May 12, 2026 17:01
Sign up for free to 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.

2 participants