ModuleInstaller for XOOPS CMS 2.7.1+
ModuleInstaller is a XOOPS admin module for managing other modules in bulk: install, uninstall, update, activate, and deactivate — plus Module Sets for focused testing (activate a named subset and deactivate everything else without uninstalling).
| Current version | 1.7.0 Alpha 1 (2026-07-30) |
| Previous baseline | 1.5.1 Final (2022-12-15) |
| License | GNU GPL 2.0 |
| Author | Michael Beck (Mamba) |
Full history: CHANGELOG.md · docs/changelog.txt · docs/lang_diff.txt
How-to: docs/TUTORIAL.md
| Requirement | Minimum |
|---|---|
| XOOPS | 2.7.0+ |
| PHP | 8.2+ |
| mtools | 1.2.0+ (must be installed; does not need to be active) |
| MySQL | 5.5+ |
⚠️ mtools must be installed, not just present. Extracting the mtools files intomodules/mtools/is not enough — ModuleInstaller verifies mtools' installed version (≥ 1.2.0) via Admin → System → Modules and refuses to install if mtools is present on disk but not installed. mtools does not need to be activated (installed-but-inactive is fine).
1.5.1 required only PHP 7.4+ and XOOPS 2.5.10+ and did not depend on mtools.
- Install — install selected uninstalled modules
- Update — run module update scripts for selected installed modules (version mismatches pre-selected; optional “needs update only” filter)
- Uninstall — remove selected modules (
systemandmoduleinstallerare protected) - Activate / Deactivate — toggle active state without uninstalling
Workflow
- Open a bulk tab under Admin → Installer.
- Optionally Apply set to check Yes for members of a saved set on that page.
- Filter the list, use Select All / Un-Select All, or click logo/name to toggle.
- Light-green rows are selected; the title and sticky bar show N selected.
- Click Continue, review the result log.
Bulk Update uses the System modulesadmin helpers shipped with XOOPS core.
- Counts for sets, updates available, active / installed / on-disk modules
- Link to restore the last Focus snapshot
- Optional sample data buttons (mtools
TestdataButtons) controlled by preference Show sample-data buttons?
On Installer home, load shipped sample module sets (YAML — not DB tables), including:
| Set | Modules |
|---|---|
| PM, Profile & Protector | pm, profile, protector |
Then open Module Sets to Install or Focus that set. Export / clear sample sets are available from the same buttons.
Admin → Installer → Module Sets
Named lists of modules stored as YAML under:
XOOPS_VAR_PATH/configs/moduleinstaller/sets/
| Action | Effect |
|---|---|
| Create / Edit / Duplicate / Delete | Manage set definitions (not the modules themselves) |
| Snapshot active | New set from modules currently active |
| Import / Export YAML | Share sets between sites |
| Activate / Deactivate / Install / Uninstall | Apply only to set members |
| Focus | Activate set members; deactivate all other non-protected modules |
- Focus saves an auto-snapshot of active modules first so you can restore later.
- Members listed in a set but missing on disk are skipped with a notice; apply never fatals.
systemandmoduleinstallerare never uninstalled or force-deactivated by Focus.
- Control Panel look & feel comes from XOOPS ModuleAdmin and the active admin theme.
- Module CSS (
assets/css/admin.css) only adds installer helpers (selection highlight, filter, sticky bar, set panels). - Keyboard:
/focuses filter;Aselects all visible Yes (when not typing in a field).
AdminBulkPage— CP bulk UI (serve()), assets, Yes/No table, reportsModuleActionService/ModuleActionResult— multi-module actions with per-item resultsModuleCatalog— installed / available / active inventory and candidatesSet\*— set model, YAML repository, resolver, applierbootstrap.php+ mtoolsConsumerRuntimedependency check- Admin input via Xmf\Request; CSRF on bulk POST and set mutations
- Install mtools ≥ 1.2.0 (leave inactive if you prefer).
- Extract this module into
modules/moduleinstaller/. - In XOOPS Admin → System → Modules, install Installer.
- Open Admin → Installer and use the tabs as needed.
Standard XOOPS module install rules apply.
Ops manual: XOOPS Operations Manual.
- Install mtools ≥ 1.2.0 if missing.
- Upload the new module files over the old tree.
- Run Update on ModuleInstaller in System → Modules.
- Confirm PHP ≥ 8.2 and XOOPS ≥ 2.7.0.
- (Optional) Load sample module sets from Installer home.
DevOps baseline (same pattern as other XOOPS modules — module-devops):
cd modules/moduleinstaller
composer install
composer qa # CS-Fixer check → PHPStan → Rector dry-run → PHPUnit
composer cs:fix # auto-fix style
composer analyse # PHPStan (phpstan.neon.dist)
composer test # vendor/bin/phpunitWithout local vendor/, unit tests still boot via preloads/autoloader.php + site xoops_lib + sibling mtools when present.
- Unit tests:
tests/Unit/· helpers:tests/helpers/ - Static analysis:
phpstan.neon.dist,phpstan-bootstrap.php,stubs/xoops.stub - Style:
.php-cs-fixer.dist.php· Rector:rector.php - CI:
.github/workflows/(CI, release ZIP viagit archive, optional SonarCloud) - Roadmap: docs/TODO.md
- Contributing: CONTRIBUTING.md /
.github/CONTRIBUTING.md
- In-repo tutorial: docs/TUTORIAL.md
- Tutorial (GitBook): xoops-moduleinstaller
- Tutorial source: XoopsDocs/moduleinstaller-tutorial
- Translations: Transifex
- Project site: https://xoops.org
- Next-gen XOOPS: https://github.com/XOOPS
GNU General Public License v2.0 — see docs/licence.txt.
