mirror of
https://github.com/derrod/legendary.git
synced 2024-12-22 17:55:27 +00:00
[core/utils] Remove missing folder creation
Instead, the manifest will just use zero-byte ".keep" files in empty folders, so they are still created when a bottle is downloaded.
This commit is contained in:
parent
72215875ee
commit
0f481e1f31
|
@ -33,7 +33,7 @@ from legendary.models.game import *
|
||||||
from legendary.models.json_manifest import JSONManifest
|
from legendary.models.json_manifest import JSONManifest
|
||||||
from legendary.models.manifest import Manifest, ManifestMeta
|
from legendary.models.manifest import Manifest, ManifestMeta
|
||||||
from legendary.models.chunk import Chunk
|
from legendary.models.chunk import Chunk
|
||||||
from legendary.utils.crossover import mac_find_crossover_apps, mac_get_crossover_version, EMPTY_BOTTLE_DIRECTORIES
|
from legendary.utils.crossover import mac_find_crossover_apps, mac_get_crossover_version
|
||||||
from legendary.utils.egl_crypt import decrypt_epic_data
|
from legendary.utils.egl_crypt import decrypt_epic_data
|
||||||
from legendary.utils.env import is_windows_mac_or_pyi
|
from legendary.utils.env import is_windows_mac_or_pyi
|
||||||
from legendary.utils.eos import EOSOverlayApp, query_registry_entries
|
from legendary.utils.eos import EOSOverlayApp, query_registry_entries
|
||||||
|
@ -1865,11 +1865,6 @@ class LegendaryCore:
|
||||||
bottles_dir = os.path.expanduser('~/Library/Application Support/CrossOver/Bottles')
|
bottles_dir = os.path.expanduser('~/Library/Application Support/CrossOver/Bottles')
|
||||||
path = os.path.join(bottles_dir, bottle_name)
|
path = os.path.join(bottles_dir, bottle_name)
|
||||||
|
|
||||||
self.log.info('Creating missing folders...')
|
|
||||||
os.makedirs(os.path.join(path, 'dosdevices'), exist_ok=True)
|
|
||||||
for _dir in EMPTY_BOTTLE_DIRECTORIES:
|
|
||||||
os.makedirs(os.path.join(path, 'drive_c', _dir), exist_ok=True)
|
|
||||||
|
|
||||||
self.log.info('Creating bottle symlinks...')
|
self.log.info('Creating bottle symlinks...')
|
||||||
symlinks = [
|
symlinks = [
|
||||||
('dosdevices/c:', '../drive_c'),
|
('dosdevices/c:', '../drive_c'),
|
||||||
|
|
|
@ -5,50 +5,6 @@ import subprocess
|
||||||
|
|
||||||
logger = logging.getLogger('CXHelpers')
|
logger = logging.getLogger('CXHelpers')
|
||||||
|
|
||||||
# all the empty folders found in a freshly created bottle that we will need to create
|
|
||||||
EMPTY_BOTTLE_DIRECTORIES = [
|
|
||||||
'Program Files/Common Files/Microsoft Shared/TextConv',
|
|
||||||
'ProgramData/Microsoft/Windows/Start Menu/Programs/Administrative Tools',
|
|
||||||
'ProgramData/Microsoft/Windows/Start Menu/Programs/StartUp',
|
|
||||||
'ProgramData/Microsoft/Windows/Templates',
|
|
||||||
'users/crossover/AppData/LocalLow',
|
|
||||||
'users/crossover/Application Data/Microsoft/Windows/Themes',
|
|
||||||
'users/crossover/Contacts',
|
|
||||||
'users/crossover/Cookies',
|
|
||||||
'users/crossover/Desktop',
|
|
||||||
'users/crossover/Favorites',
|
|
||||||
'users/crossover/Links',
|
|
||||||
'users/crossover/Local Settings/Application Data/Microsoft',
|
|
||||||
'users/crossover/Local Settings/History',
|
|
||||||
'users/crossover/Local Settings/Temporary Internet Files',
|
|
||||||
'users/crossover/NetHood',
|
|
||||||
'users/crossover/PrintHood',
|
|
||||||
'users/crossover/Recent',
|
|
||||||
'users/crossover/Saved Games',
|
|
||||||
'users/crossover/Searches',
|
|
||||||
'users/crossover/SendTo',
|
|
||||||
'users/crossover/Start Menu/Programs/Administrative Tools',
|
|
||||||
'users/crossover/Start Menu/Programs/StartUp',
|
|
||||||
'users/crossover/Temp',
|
|
||||||
'users/Public/Desktop',
|
|
||||||
'users/Public/Documents',
|
|
||||||
'users/Public/Favorites',
|
|
||||||
'users/Public/Music',
|
|
||||||
'users/Public/Pictures',
|
|
||||||
'users/Public/Videos',
|
|
||||||
'windows/Fonts',
|
|
||||||
'windows/help',
|
|
||||||
'windows/logs',
|
|
||||||
'windows/Microsoft.NET/DirectX for Managed Code',
|
|
||||||
'windows/system32/mui',
|
|
||||||
'windows/system32/spool/printers',
|
|
||||||
'windows/system32/tasks',
|
|
||||||
'windows/syswow64/drivers',
|
|
||||||
'windows/syswow64/mui',
|
|
||||||
'windows/tasks',
|
|
||||||
'windows/temp'
|
|
||||||
]
|
|
||||||
|
|
||||||
|
|
||||||
def mac_get_crossover_version(app_path):
|
def mac_get_crossover_version(app_path):
|
||||||
try:
|
try:
|
||||||
|
|
Loading…
Reference in a new issue