mirror of
https://github.com/parchlinux/calamares.git
synced 2025-02-28 12:55:49 -05:00
Module descriptors are now module.desc, no configuration allowed inside. Module config files are <modulename>.conf, installed in share/calamares/modules. settings.conf is read from /etc/calamares, then share/calamares, and if running with --debug also in the current dir. Module config files are read from /etc/calamares/modules, then share/calamares/modules, and if running with --debug also in src/modules/<modulename> relative to the current dir.
18 lines
No EOL
1.1 KiB
Markdown
18 lines
No EOL
1.1 KiB
Markdown
Calamares modules directory
|
|
===
|
|
|
|
Calamares modules are plugins that provide features like installer pages, batch jobs, etc. Each Calamares module lives in its own directory.
|
|
|
|
### Qt plugin viewmodules
|
|
|
|
Currently the only way to write a module which exposes one or more installer pages (viewmodule) is through a Qt plugin. Viewmodules should implement `Calamares::ViewStep`. They can also implement `Calamares::Job` to provide jobs.
|
|
|
|
To add a Qt plugin module, put it in a subdirectory and make sure it has a `module.desc` and a `CMakeLists.txt` with a `calamares_add_plugin` call. It will be picked up automatically by our CMake magic.
|
|
|
|
|
|
### Python and process jobmodules
|
|
|
|
Batch jobs for Calamares can be written as Python scripts or as generic commands (shell scripts, external programs, etc.).
|
|
To add a Python or process jobmodule, put it in a subdirectory and make sure it has a `module.desc`. It will be picked up automatically by our CMake magic. `CMakeLists.txt` is not used for Python and process jobmodules.
|
|
|
|
All code in Python job modules must obey PEP8, the only exception are `libcalamares.globalstorage` keys, which should always be camelCaseWithLowerCaseInitial. |