add hook for pyinstaller to add nixio info.json

This commit is contained in:
Jan Grewe 2021-03-22 22:50:04 +01:00
parent d8dee7ff56
commit 6d3cb44748

10
hook-nixio.py Normal file
View File

@ -0,0 +1,10 @@
import site
import glob
import os
dist_sites = site.getsitepackages()
for ds in dist_sites:
nix_dirs = glob.glob(os.path.join(ds, "nixio/info.json"))
if len(nix_dirs) > 0:
datas = [(nix_dirs[0], 'nixio')]
break