How to install a library for global use?

Hi to all!
I know how to search for a library in platformio/Libraries, I click on Add to Project and it’s installed into that project. But if I start a new project that needs that library I have to do this all over again. Is there an easy way to install a library so it’s available to all new projects?

Thank you in advance and please don’t get angry at the newbie :joy:

Only from the CLI or setting a lib_extra_dirs in every project to a folder which contains the collected library folders.

Global libraries are not recommended, due to reproducability issues (unless you specify somewhere else where to get the needed library and at which exact version, other people will have problems compiling – specifying them by a unique name and version in lib_deps eliminates these problems).

1 Like