mirror of
https://github.com/spalencsar/bearhub.git
synced 2026-07-07 00:04:15 +02:00
[appimage] refactoring: LOCAL_PATH constant renamed to APPIMAGE_SHARED_DIR
This commit is contained in:
@@ -7,8 +7,8 @@ from bauh.api.paths import CONFIG_DIR, TEMP_DIR, CACHE_DIR, BINARIES_DIR, SHARED
|
|||||||
from bauh.commons import resource
|
from bauh.commons import resource
|
||||||
|
|
||||||
ROOT_DIR = os.path.dirname(os.path.abspath(__file__))
|
ROOT_DIR = os.path.dirname(os.path.abspath(__file__))
|
||||||
LOCAL_PATH = f'{SHARED_FILES_DIR}/appimage'
|
APPIMAGE_SHARED_DIR = f'{SHARED_FILES_DIR}/appimage'
|
||||||
INSTALLATION_PATH = f'{LOCAL_PATH}/installed/'
|
INSTALLATION_PATH = f'{APPIMAGE_SHARED_DIR}/installed/'
|
||||||
SUGGESTIONS_FILE = f'https://raw.githubusercontent.com/vinifmor/{__app_name__}-files/master/appimage/suggestions.txt'
|
SUGGESTIONS_FILE = f'https://raw.githubusercontent.com/vinifmor/{__app_name__}-files/master/appimage/suggestions.txt'
|
||||||
CONFIG_FILE = f'{CONFIG_DIR}/appimage.yml'
|
CONFIG_FILE = f'{CONFIG_DIR}/appimage.yml'
|
||||||
APPIMAGE_CONFIG_DIR = f'{CONFIG_DIR}/appimage'
|
APPIMAGE_CONFIG_DIR = f'{CONFIG_DIR}/appimage'
|
||||||
|
|||||||
@@ -28,7 +28,7 @@ from bauh.commons import resource
|
|||||||
from bauh.commons.boot import CreateConfigFile
|
from bauh.commons.boot import CreateConfigFile
|
||||||
from bauh.commons.html import bold
|
from bauh.commons.html import bold
|
||||||
from bauh.commons.system import SystemProcess, new_subprocess, ProcessHandler, run_cmd, SimpleProcess
|
from bauh.commons.system import SystemProcess, new_subprocess, ProcessHandler, run_cmd, SimpleProcess
|
||||||
from bauh.gems.appimage import query, INSTALLATION_PATH, LOCAL_PATH, ROOT_DIR, \
|
from bauh.gems.appimage import query, INSTALLATION_PATH, APPIMAGE_SHARED_DIR, ROOT_DIR, \
|
||||||
APPIMAGE_CONFIG_DIR, UPDATES_IGNORED_FILE, util, get_default_manual_installation_file_dir, DATABASE_APPS_FILE, \
|
APPIMAGE_CONFIG_DIR, UPDATES_IGNORED_FILE, util, get_default_manual_installation_file_dir, DATABASE_APPS_FILE, \
|
||||||
DATABASE_RELEASES_FILE, APPIMAGE_CACHE_DIR, get_icon_path, DOWNLOAD_DIR
|
DATABASE_RELEASES_FILE, APPIMAGE_CACHE_DIR, get_icon_path, DOWNLOAD_DIR
|
||||||
from bauh.gems.appimage.config import AppImageConfigManager
|
from bauh.gems.appimage.config import AppImageConfigManager
|
||||||
@@ -810,7 +810,7 @@ class AppImageManager(SoftwareManager):
|
|||||||
return []
|
return []
|
||||||
|
|
||||||
def clear_data(self, logs: bool = True):
|
def clear_data(self, logs: bool = True):
|
||||||
for f in glob.glob('{}/*.db'.format(LOCAL_PATH)):
|
for f in glob.glob('{}/*.db'.format(APPIMAGE_SHARED_DIR)):
|
||||||
try:
|
try:
|
||||||
if logs:
|
if logs:
|
||||||
print('[bauh][appimage] Deleting {}'.format(f))
|
print('[bauh][appimage] Deleting {}'.format(f))
|
||||||
|
|||||||
Reference in New Issue
Block a user