Skip to content

Commit

Permalink
fixed a startup issue
Browse files Browse the repository at this point in the history
  • Loading branch information
eliranwong committed Oct 26, 2024
1 parent 32869f6 commit 8c1fcf6
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
# https://packaging.python.org/en/latest/guides/distributing-packages-using-setuptools/
setup(
name=package,
version="0.1.21",
version="0.1.22",
python_requires=">=3.8, <3.13",
description=f"UniqueBible App is a cross-platform & offline bible application, integrated with high-quality resources and unique features. Developers: Eliran Wong and Oliver Tseng",
long_description=long_description,
Expand Down
10 changes: 5 additions & 5 deletions uniquebible/util/ConfigUtil.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,10 +62,6 @@ def setup(noQt=None, cli=None, enableCli=None, enableApiServer=None, enableHttpS
ubaUserDir = os.path.join(os.path.expanduser("~"), "UniqueBible")
config.ubaUserDir = ubaUserDir if os.path.isdir(ubaUserDir) else os.getcwd()
config.packageDir = str(importlib.resources.files("uniquebible"))

userMarvelData = os.path.join(config.ubaUserDir, "marvelData")
if config.marvelData == "marvelData" and os.path.isdir(userMarvelData):
config.marvelData = userMarvelData

# check running mode
config.runMode = sys.argv[1] if len(sys.argv) > 1 else ""
Expand Down Expand Up @@ -825,7 +821,11 @@ def getCurrentVenvDir():
config.help["marvelData"] = """
# Specify the folder path of resources"""
if not hasattr(config, "marvelData") or not os.path.isdir(config.marvelData):
config.marvelData = "marvelData"
userMarvelData = os.path.join(config.ubaUserDir, "marvelData")
if os.path.isdir(userMarvelData):
config.marvelData = userMarvelData
else:
config.marvelData = "marvelData"
config.help["marvelDataPublic"] = """
# Public marvelData Directory."""
if not hasattr(config, "marvelDataPublic") or not os.path.isdir(config.marvelData):
Expand Down

0 comments on commit 8c1fcf6

Please sign in to comment.