Import code

This commit is contained in:
Paco8 committed 2023-01-22 16:20:27 +01:00
1 parent 9b88a6ecde
commit 054d387e37
20 files changed
+2348

No files matched your search

+21
View File
@@ -0,0 +1,21 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
try: # Kodi >= 19
from xbmcvfs import translatePath
except ImportError: # Kodi 18
from xbmc import translatePath
import os
import xbmcaddon
from .log import LOG
addon = xbmcaddon.Addon()
profile_dir = translatePath(addon.getAddonInfo('profile'))
LOG("Profile directory: {}".format(profile_dir))
if not os.path.exists(profile_dir):
LOG('Creating {}'.format(profile_dir))
os.makedirs(profile_dir)