3liz / qgis-plugin-manager

CLI tools for installing QGIS Plugins
GNU General Public License v3.0
14 stars 2 forks source link

Activate plug-ins on conda version of QGIS #49

Closed barnabasharris closed 1 year ago

barnabasharris commented 2 years ago

After successful installation, I'm trying to activate plug-ins in a fresh, conda (actually, micromamba) installed version of QGIS.

The plug-ins dir is here: /home/user/mm/envs/qgis/plugins

general QGIS folder structure is:

(qgis) [user@login01 qgis]$ find . -maxdepth 1
.
./mkspecs
./cmake
./ssl
./x86_64-conda-linux-gnu
./qml
./doc
./var
./plugins
./man
./libexec
./x86_64-conda_cos6-linux-gnu
./conda-meta
./pkgconfig
./phrasebooks
./docs
./compiler_compat
./qsci
./bin
./include
./fonts
./share
./etc
./sbin
./translations
./lib

Output from qgis-plugin-manager list

QGIS version : 3.22.11
List all plugins in /lustre/home/user/mm/envs/qgis/plugins

----------------------------------------------------------------------------------------------------------------------------------------------------------------------------
|  Folder ⬇  |  Name                      |  Version  |  Flags   |  QGIS min  |  QGIS max  |  Author                                                 |  Folder rights  |  Action ⚠  |
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------
|mmqgis      |mmqgis                      |2021.9.10  |          |2.99        |3.99        |Michael Minn                                             |user : 0o755  |   |
|rvt-qgis    |Relief Visualization Toolbox|0.9.4.1    |Processing|3.0         |            |ZRC SAZU and University of Ljubljana (UL FGG), Žiga Maroh|user : 0o755  |   |
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------

Yet when I call qgis_process list, this plug-in is not listed in the providers.

Any way I can the plug-in to appear to qgis_process ?

Gustry commented 2 years ago

In QGIS Desktop, plugins need to be "activated". Similar to the checkbox you have in your graphical QGIS plugin manager. The plugin is installed on the computer but not activated (not checked).

In QGIS Server, plugins needs to be in a folder only.

To simulate the checkbox, in your QGIS3.ini file, you should have a section like this :

[PythonPlugins]
rvt-qgis=true
mmqgis=true

The readme can be updated. Not sure if this tool can find and edit the INI file. It doesn't know if you are on desktop or server.

barnabasharris commented 2 years ago

Hi thank you for the explanation but I cannot find the QGIS3.ini file - where is it located in my directory structure?

Gustry commented 2 years ago

https://docs.qgis.org/3.22/en/docs/user_manual/introduction/qgis_configuration.html#deploying-qgis-within-an-organization

In QGIS Desktop -> Settings -> Profile -> Open current profile folder, then it's in the QGIS folder for me.

barnabasharris commented 2 years ago

Thank you! Mine was located at: /home/user/.local/share/QGIS/QGIS3/profiles/default/QGIS/QGIS.ini

barnabasharris commented 2 years ago

QGIS.ini located at above location

Gustry commented 2 years ago

Keeping the ticket open for the readme and the idea.

barnabasharris commented 2 years ago

For completeness, I discovered that I should have been running / installing plug-ins using qgis-plugin-manager in the following directory: /home/user/.local/share/QGIS/QGIS3/profiles/default/python/plugins

Gustry commented 2 years ago

Yes indeed. Or use the environment variable QGIS_PLUGINPATH https://github.com/3liz/qgis-plugin-manager/blob/master/README.md#utilisation

Gustry commented 1 year ago

I have update the readme.md with 0589423 about these notes.