You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

пре 4 година
пре 4 година
пре 4 година
123456789101112131415161718192021222324
  1. import os
  2. from pathlib import Path
  3. import config as cfg
  4. def app_root_dir(pvd: str) -> str:
  5. basedir = Path(os.path.abspath(os.path.dirname(__file__)))
  6. return os.path.join(basedir.parent, cfg.DIR_APP_ROOT, pvd)
  7. def doc_root_dir() -> str:
  8. basedir = Path(os.path.abspath(os.path.dirname(__file__)))
  9. return os.path.join(basedir.parent, cfg.DIR_DOC_ROOT)
  10. def resource_dir(pvd: str) -> str:
  11. basedir = Path(os.path.abspath(os.path.dirname(__file__)))
  12. return os.path.join(basedir.parent, cfg.DIR_RESOURCE, pvd)
  13. def template_dir() -> str:
  14. basedir = Path(os.path.abspath(os.path.dirname(__file__)))
  15. return os.path.join(basedir.parent, cfg.DIR_TEMPLATE)