Contains scripts to perform automated testing and deployment for QGIS plugins. These scripts are written for and tested on GitHub, Travis-CI, github workflows and Transifex.
i18n
folder can be omitted from the Git repositorychangelog
section in the metadata.txt can be populated if the CHANGELOG.md is presentexperimental
flag according to the tag if needed:book: For further information, see the documentation.
QGIS-Plugin-CI is best served if you use these two conventions :
usage: qgis-plugin-ci [-h] [-v]
{package,changelog,release,pull-translation,push-translation}
...
optional arguments:
-h, --help show this help message and exit
-v, --version print the version and exit
commands:
qgis-plugin-ci command
{package,changelog,release,pull-translation,push-translation}
package creates an archive of the plugin
changelog gets the changelog content
release release the plugin
pull-translation pull translations from Transifex
push-translation update strings and push translations
git archive
is used to bundle the plugin)..qgis-plugin-ci
or in setup.cfg
or pyproject.toml
with a [qgis-plugin-ci]
section (see docs/configuration/options.md
for details).metadata.txt
file with the following fields:
See parameters.py
for more parameters and details. Notice that the name of this directory will be used for the zip file.
import plugin_path.resources_rc
When releasing, you can publish the plugin :
Both can be achieved in the same process.
In the case of a pre-release (either from the tag name according to Semantic Versioning or from the GitHub release), the plugin will be flagged as experimental.
The tool will recognise any label use as a suffix to flag it as pre-release :
10.1.0-beta1
3.4.0-rc.2
In any Python module, you can have a global variable as DEBUG = True
, which will be changed to False
when packaging the plugin.
QGIS-Plugin-CI can generate the plugins.xml
file, per plugin.
If you want to merge many XML files into one to have a single QGIS plugin repository providing many plugins,
you should check QGIS-Plugin-Repo.
It's designed to run on CI after QGIS-Plugin-CI.