Install Addons using FreeCAD console

Need help, or want to share a macro? Post here!
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Post Reply
okesaku
Posts: 2
Joined: Wed Feb 26, 2020 1:30 pm

Install Addons using FreeCAD console

Post by okesaku »

Hello,

I'm looking for the way to install addons with FreeCAD console, not GUI.
I found AddonManager package and AddonsInstaller python class in the console, but I don't know how to use them.

Can anyone help me?

FreeCAD ver. 0.18.4
Host OS: ubuntu 18.04

Thanks
vocx
Veteran
Posts: 5197
Joined: Thu Oct 18, 2018 9:18 pm

Re: Install Addons using FreeCAD console

Post by vocx »

okesaku wrote: Wed Feb 26, 2020 1:39 pm ...
I found AddonManager package and AddonsInstaller python class in the console, but I don't know how to use them....
The Addon Manager at the moment doesn't have a proper scripting interface, so its code is tightly integrated into the graphical interface.

There was a discussion to refactor it into simpler classes and methods so that it could be used without the interface, and a preliminary script was created, but it hasn't been merged into the master code. A developer needs look into this for a while.

[Feature Request] Ability to access FreeCAD Addons Manager from the CLI (w/o GUI)

How to run Addon Manager in Headless mode?

Other than that you can basically install everything manually by downloading the workbench that you want in a zip archive, and then unpacking it in your personal ~/.FreeCAD/Mod/ directory. That's basically what the Addon Manager does.
Always add the important information to your posts if you need help. Also see Tutorials and Video tutorials.
To support the documentation effort, and code development, your donation is appreciated: liberapay.com/FreeCAD.
okesaku
Posts: 2
Joined: Wed Feb 26, 2020 1:30 pm

Re: Install Addons using FreeCAD console

Post by okesaku »

Hello vocx,

Thank you for your reply.
Other than that you can basically install everything manually by downloading the workbench that you want in a zip archive, and then unpacking it in your personal ~/.FreeCAD/Mod/ directory. That's basically what the Addon Manager does.
Oh, this helps me a lot.
I want to make a docker container that has FreeCAD and some addons preinstalled, so Dockerfile with such instruction would work as I expected.

Thank you!
User avatar
Kunda1
Veteran
Posts: 13434
Joined: Thu Jan 05, 2017 9:03 pm

Re: Install Addons using FreeCAD console

Post by Kunda1 »

I was working on that feature and got too far into the weeds to finish it. But yes, the add-on manager is a glorified frontend for git-python .
All the add-ons are tracked using git AFAIR. There are some settings that get implemented in the user config files that are specific to each add-on/external workbench. And you may need to add those manually or just run FreeCAD GUI once to activate the workbenches (for that to happen).
Alone you go faster. Together we go farther
Please mark thread [Solved]
Want to contribute back to FC? Checkout:
'good first issues' | Open TODOs and FIXMEs | How to Help FreeCAD | How to report Bugs
Post Reply