cad stability
This commit is contained in:
parent
f59bb9d801
commit
fe714b1123
40 changed files with 1655 additions and 49 deletions
19
cad_generation/main.py
Normal file
19
cad_generation/main.py
Normal file
|
@ -0,0 +1,19 @@
|
|||
import requests
|
||||
import FreeCAD as App
|
||||
from helper.fs import FS
|
||||
from scenarios.robossembler_freecad_export_scenario import RobossemblerFreeCadExportScenario
|
||||
import shutil
|
||||
import os
|
||||
import FreeCADGui as Gui
|
||||
|
||||
|
||||
def main():
|
||||
env = FS.readJSON('./env.json')
|
||||
App.openDocument(env.get('doc'))
|
||||
RobossemblerFreeCadExportScenario().call(env.get('out'))
|
||||
requests.post(url=env.get('resultURL'), files={'zip': open(env.get('out') + '/' + 'generation.zip', "rb"), 'id':env.get('projectId')})
|
||||
os.remove('./generation.zip')
|
||||
App.closeDocument(App.ActiveDocument.Name)
|
||||
freecadQTWindow = Gui.getMainWindow()
|
||||
freecadQTWindow.close()
|
||||
main()
|
Loading…
Add table
Add a link
Reference in a new issue