Skip to content

Add Module system#12

Draft
soymadip wants to merge 10 commits into
mainfrom
feat/module-system
Draft

Add Module system#12
soymadip wants to merge 10 commits into
mainfrom
feat/module-system

Conversation

@soymadip

@soymadip soymadip commented Dec 26, 2025

Copy link
Copy Markdown
Member

This PR introduces a module system for myctl.

Modules are loadable, trusted Bash components that extend myctl functionality while keeping the core code clean and maintainable.

Checklist

  • Clear plugin entry function (myctl::<plugin>())

  • Strict name spacing (no global functions/vars)

  • Plugins separated from core code

  • System + user plugin directories supported

  • Deterministic plugin load order

  • Cold-load rule (no logic at source time)

  • Plugin metadata (name, description, permissions)

  • Soft permission model (declared capabilities)

  • Permission check before execution

  • Guarded execution helpers (myctl_api::exec)

  • Dangerous commands blocked or warned

  • Core variables marked readonly

  • Plugins listed in myctl help

  • Clear security notice (plugins are trusted code)

Module Scoping

By default, modules have limited filesystem access
Module code:
/usr/lib/myctl/modules/screenshot/
~/.local/lib/myctl/modules/screenshot/

Module config:
~/.config/myctl/myctl.yml -> screenshot.*

Module cache / runtime data:
~/.cache/myctl/modules/screenshot/

@soymadip soymadip linked an issue Dec 26, 2025 that may be closed by this pull request
4 tasks
@soymadip soymadip marked this pull request as draft December 26, 2025 19:13
@soymadip soymadip self-assigned this Dec 26, 2025
@soymadip soymadip marked this pull request as ready for review December 28, 2025 15:09
@soymadip soymadip marked this pull request as draft December 28, 2025 15:10
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.

MyCTL Extension System

1 participant