Skip to content

Heroic-Games-Launcher/heroic-gogdl

Repository files navigation

heroic-gogdl

GOG download module for Heroic Games Launcher

Important note

This is not user friendly cli, it's meant to be used by some other application wanting to download game files, manage cloud saves or conveniently launch the game

Contributing

The only python dependency needed at this moment is requests

You can install it using your Linux distribution package manager or using pip

pip install requests

To run a code locally, use bin/gogdl script, which is a convenient python wrapper

gogdl now manages authentication, so it no longer needs --token parameter, although you now need to provide a path to json file where the tokens will be stored Heroic uses $XDG_CONFIG_HOME/heroic/gog_store/auth.json

Here is the command to pull the source code

git clone https://github.com/Heroic-Games-Launcher/heroic-gogdl
cd heroic-gogdl
python -m venv venv
. venv/bin/activate
pip install .
gogdl --help

If you have any questions ask on our Discord or through GitHub issue

Building PyInstaller executable

If you wish to test the gogdl in Heroic flatpak you likely need to build gogdl executable using pyinstaller

  • Get pyinstaller
pip install pyinstaller
  • Build the binary (assuming you are in heroic-gogdl direcory)
pip install -e . # Ensure you build the C code to python module in current directory
pyinstaller --onefile --name gogdl gogdl/cli.py

Building zipapp executable

For Linux it is especially recommended to use zipapp format, as it allows gogdl by relying on OS provided python interpretter

  • Install gogdl and its dependencies into build directory
pip install . --target build 
  • Copy custom entry point - it's required to unpack the C lib to a known location

Right now the entry point is hardcoded for Linux support only

cp zipapp_main.py build/__main__.py
  • Package
python -m zipapp --output dist/gogdl --python "/usr/bin/env python3" --compress build

Great resources about GOG API

About

GOG Downloading module for Heroic Games Launcher

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors