Plugin location Ubuntu\ Refresh [solved]

I try to get the RF-plugins running on Ubuntu 16.10. I located the “/usr/share/kicad/plugins” folder and copied the plugin folder into it (using this guide)

RF-Plugins

A restart and refreshing Tools->External Plugins did not activate the plugins.

Is there another location for the plugins? Do I need to install them differently on Ubuntu?

Found it. Copied the contents to

/usr/share/kicad/scripting/plugins/

Never use anything under /usr/ for your own data or files. Kicad should find plugins under your home directory in:

  • .kicad_plugins/
  • .kicad/scripting/
  • .kicad/scripting/plugins/

(on Linux).

My home directory does not have these folders.
I run

Version: 5.1.6-c6e7f7d~87~ubuntu16.04.1, release build

installed over the repository

Of course it doesn’t, you have to create them if you want to install your plugins in your home directory. KiCad doesn’t create those directories because it doesn’t install plugins by itself.

The /usr/ directory is meant for the files installed by the system administrator, either using the package manager of the system or manually if (s)he knows what he’s doing and knows it’s necessary. In this case it’s not necessary and shouldn’t be used.

Do I have to configure a path to this directory? I created the folders and copied the plugins, but Kicad does not detect them automatically.

Is there a option to change the path to the plugins?

My “personal” settings for KiCad are on"
~/.config/kicad/

This is a very slow pc (Passmark rating 750) and KiCad is one of the few applictions that still work well on it. My “regular” pc died 2 weeks ago and I’m still thinkging on what to replace it with.

Result is a bare KiCad installation, and I have not run any scripts for KiCad on this Linux box yet.

The information is found in the link which was in the original post, and in the source code of KiCad. Did you restart KiCad?

.config/ directory is meant for configuration, not runnable scripts (it’s probably some kind of Linux standard, not a KiCad thing).

This doesn’t have to be so hard for plugin users. Please give a thumbs up to this feature request.

1 Like

Yes, it’s a continual PITA.

A directory where application specific resources has to be called something, and KiCad isn’t alone in storing scripts here. For gimp, I see a couple of directories:

.config/GIMP/2.10/plug-ins
.config/GIMP/2.10/scripts

Compared to scattering all the information in app specific directories, this is preferable.

$HOME /.local/share would be for that purpose, see https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html.

Nonetheless, many applications have chosen .config. At least choice of two is better that one directory under $HOME for each application. Mozilla apps are the major holdouts in this regard.

I looked at other programs and all of them have their configurations/ plugins and addons in the home directory under ~/.<software>

I manually created .kicad and copied the plugins in both the scripting and plugins folder. It looks like

~/.kicad/plugins/
~/.kicad/scripting/

After restart and refresh external plugins it still does not recognize the plugins. I also did not find a reference to the plugin paths.

Can you follow the instruction in the document you linked to:

  • Open Tools -> Scripting Console in pcbnew
  • type import pcbnew; print pcbnew.PLUGIN_DIRECTORIES_SEARCH

What does it tell?

/usr/share/kicad/scripting
/usr/share/kicad/scripting/plugins
/home//.config/kicad/scripting
/home//.config/kicad/scripting/plugins
/home//.kicad_plugins
/home//.kicad/scripting
/home//.kicad/scripting/plugins

it looks like it should search in this folders.

The document seems to use old python2 syntax. Instead, use
import pcbnew; print(pcbnew.PLUGIN_DIRECTORIES_SEARCH)

EDIT: only if the original doesn’t work, but it seemed to work…

It looks like you don’t have a home directory there! What’s you actual user directory name in the system? Let me guess, it has a non-ascii character…

Let me guess, it has a non-ascii character…

No. Just the PCs name (e.g. = thomas). Almost all of my files and folders do not have whitespaces, points or something that may trip up certain programs

What’s the python version seen in the KiCad’s Python Shell?