Skip to content

Commit 07a500a

Browse files
committed
adding qpip option for dependency management
1 parent a999d97 commit 07a500a

4 files changed

Lines changed: 17 additions & 1 deletion

File tree

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,4 +129,5 @@ dmypy.json
129129
*.zip
130130
*.qm
131131

132-
loopstructural/embedded_external_libs/*
132+
loopstructural/embedded_external_libs/*
133+
.DS_Store

loopstructural/metadata.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,3 +24,4 @@ qgisMaximumVersion=3.99
2424
version=0.1.0
2525
changelog=
2626

27+
plugin_dependencies=qpip

loopstructural/plugin_main.py

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,18 @@
2323
__title__,
2424
__uri_homepage__,
2525
)
26+
try:
27+
import LoopStructural
28+
except ImportError:
29+
raise ImportError(
30+
"LoopStructural is not installed. Please install it using the requirements.txt file in the plugin directory."
31+
)
32+
try:
33+
import pyvistaqt
34+
except ImportError:
35+
raise ImportError(
36+
"pyvistaqt is not installed. Please install it using the requirements.txt file in the plugin directory."
37+
)
2638
from loopstructural.gui.dlg_settings import PlgOptionsFactory
2739
from loopstructural.gui.modelling.modelling_widget import ModellingWidget as Modelling
2840
from loopstructural.toolbelt import PlgLogger

loopstructural/requirements.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
pyvistaqt
2+
LoopStructural[all]

0 commit comments

Comments
 (0)