Open malutanpetronel opened 3 years ago
hmmmm that will get very tricky - the importer needs access to the FreeCAD installation to use the FreeCAD python modules.
i have opened a question in the FreeCAD Forum - have a look there too : How to Use FreeCAD Python API from outside scripts with AppImages
as a workaround you could unpack the appimage to a known location and use this as the path in the importer addon.
maybe it can be done by automagically unpacking / mounting in the background...
myappimage --appimage-extract
> my.AppImage --appimage-mount
/tmp/mount_myXXXX
# now, use another terminal or file manager to inspect the contents in the directory printed by --appimage-mount
snap:
unsquashfs “snap name”
at least on my system snap mounts the applications to /snap/*
- for freecad this results in /snap/freecad/current/
$ ll /snap/freecad/current/usr/lib/FreeCAD*
-rw-r--r-- 1 root root 182K 2023-06-09 03:59:49.000 /snap/freecad/current/usr/lib/FreeCADGui.so
-rw-r--r-- 1 root root 61K 2023-06-09 03:00:43.000 /snap/freecad/current/usr/lib/FreeCAD.so
we could just test if this path exists and if - use it..
How we can use FreeCad importer with appimage?