refactor: per-plugin subdirectory layout#2
Merged
Conversation
Moves each imported plugin into its own folder under scripts/, with the folder's internal structure mirroring the hub's scripts/ tree so a recursive copy of the plugin folder lands every file at the right path. Before: flat scripts/ with siblings lang/, data/, plus per-plugin state dirs (etc_blackboard/, etc_wunschbrett/) at the top. After: scripts/<plugin>/ holds <plugin>.lua plus its own lang/, data/, or script-named state subdir. Operator install changes from "cp -r repo/scripts/* hub/scripts/" to the per-plugin "cp -r repo/scripts/<plugin>/* hub/scripts/". README updated. Pure rename + README update; no script content changed. Hub install behaviour unchanged.
This was referenced May 6, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Moves each plugin imported in #1 into its own folder under `scripts/`. Internal structure mirrors the hub's `scripts/` tree so a recursive copy of the plugin folder still lands every file at the correct hub-relative path.
Before vs after
Before (PR #1):
```
scripts/
bot_advanced_chat.lua
etc_blackboard.lua
etc_mainecho.lua
...
lang/ <- shared across plugins
data/ <- shared across plugins
etc_blackboard/ <- script-named state dir
etc_wunschbrett/ <- script-named state dir
```
After:
```
scripts/
bot_advanced_chat/
bot_advanced_chat.lua
lang/bot_advanced_chat.lang.{en,de}
data/bot_advanced_chat_{history,members}.tbl
etc_blackboard/
etc_blackboard.lua
lang/etc_blackboard.lang.{en,de}
etc_blackboard/{t_blackboard,t_blackboardnicks}.tbl
...
```
Why
Browsing per-plugin is now one folder per plugin. Removing or updating a single plugin is a single `rm -rf` / `git rm` against one path. Future plugin folders can carry per-plugin docs, tests, or version-history files without polluting the top of the repo.
Operator install
Changes from wholesale `cp -r repo/scripts/* hub/scripts/` to per-plugin:
```sh
cp -r repo/scripts//* /opt/luadch/scripts/
```
The plugin folder's internal structure makes this drop straight into the hub's `scripts/` tree.
What this PR contains
No script content changed. The hub install behaviour is unchanged: same files at the same hub-side paths after a fresh deploy.