Skip to content

Commit

Permalink
Fix the PowerBinder command plugins not showing up in binary release
Browse files Browse the repository at this point in the history
  • Loading branch information
emersonrp committed Jan 26, 2025
1 parent 64b4581 commit 1a8bc4d
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions UI/PowerBinderDialog.py
Original file line number Diff line number Diff line change
Expand Up @@ -89,8 +89,11 @@ def Show(self, show = True):

# Load plugins / modules from UI/PowerBinderCommand directory
def LoadModules(self):
base_path = getattr(sys, '_MEIPASS', os.path.dirname(os.path.abspath(__file__)))
path = Path(base_path) / 'PowerBinderCommand'
if base_path := getattr(sys, '_MEIPASS', None):
path = Path(base_path) / 'UI' / 'PowerBinderCommand'
else:
path = Path(os.path.dirname(os.path.abspath(__file__))) / 'PowerBinderCommand'

for package_file in sorted(path.glob('*.py')):
package = package_file.stem
if package == '__init__': continue
Expand Down

0 comments on commit 1a8bc4d

Please sign in to comment.