diff options
| author | vg <vgm+dev@devys.org> | 2026-01-14 16:24:40 +0100 |
|---|---|---|
| committer | vg <vgm+dev@devys.org> | 2026-01-14 16:24:40 +0100 |
| commit | 4a518beaf9b6fad9b93bcc2f2119f5612b3fd0c1 (patch) | |
| tree | 4689e5cab4750f23ec63e1ade7ff005535531948 /gamechestcli | |
| parent | f946248aa5b204ee6642adfeb6ede835ac30915d (diff) | |
| download | gamechest-4a518beaf9b6fad9b93bcc2f2119f5612b3fd0c1.tar.gz gamechest-4a518beaf9b6fad9b93bcc2f2119f5612b3fd0c1.tar.bz2 gamechest-4a518beaf9b6fad9b93bcc2f2119f5612b3fd0c1.zip | |
git-sync on ditawip
Diffstat (limited to 'gamechestcli')
| -rw-r--r-- | gamechestcli/gamechest/cliactions/install.py | 17 |
1 files changed, 13 insertions, 4 deletions
diff --git a/gamechestcli/gamechest/cliactions/install.py b/gamechestcli/gamechest/cliactions/install.py index 508dd48..90e9ac4 100644 --- a/gamechestcli/gamechest/cliactions/install.py +++ b/gamechestcli/gamechest/cliactions/install.py @@ -8,12 +8,21 @@ from ..statusdb import StatusDB def install_game(status_db, game_info): remote_basedir = config.get_remote_basedir() - source = f'{remote_basedir}/{game_info["package_name"]}' + package_name = game_info.get("package_name") dest = config.get_games_install_basedir() / game_info['id'] dest.mkdir(parents=True, exist_ok=True) - title = 'Installing game...' - task = functools.partial(Install, source, dest) - processor.process_task(title, task) + # now as of 2026-01-14: not having a package_name or having it set to none + # means there is no installation archive (all is managed by the runner), + # thus consider it installed with version given without extracting + # anything. + if package_name: + title = 'Installing game...' + source = f'{remote_basedir}/{package_name}' + task = functools.partial(Install, source, dest) + processor.process_task(title, task) + else: + (dest / "dummy").mkdir(parents=True, exist_ok=True) + status_db.set_installed(game_info) |
