It seems that you're using an outdated browser. Some things may not work as they should (or don't work at all).
We suggest you upgrade newer and better browser like: Chrome, Firefox, Internet Explorer or Opera

×
avatar
TheBigCore: (…)
Can’t you run the Linux build using Windows Subsystem for Linux?
Here is my final script. I split the parts and it seems to work. Just one final question: some commands are in both parts of the script. Are they necessary? e.g. is it necessary to have --save-serials in the caching-part so that the downloader knows to cache this things? what are unnecessary doublings in my script? Thanks for your help :)

# CACHING
lgogdownloader \
--login \
--enable-login-gui \
--update-cache \
--language de,en \
--info-threads 24 \
--cache-valid 604800 \
--automatic-xml-creation \
--no-platform-detection \
--save-serials \
--save-changelogs \

# DOWNLOAD
cd $GAME_DIR

lgogdownloader \
--download \
--use-cache \
--game '^(?!.*(the_witcher_3).*).*$' \
--directory . \
--platform w,l \
--language de,en \
--save-serials \
--automatic-xml-creation \
--save-changelogs \
--threads 4 \

edit: the manpage doesn't help :(
edit2: here's my final script. Let it ran several times and it works as intended:

#!/bin/sh

set -e
set -u

GAME_DIR="$HOME/media/raid0/data/Games/GOG-Games"

ls $GAME_DIR > /dev/null || { echo "ERROR: Gamedir doesn't exists." >&2 ; exit 1 ; }

# CACHE ALL GAMES FROM GOG.COM
lgogdownloader \
--login \
--enable-login-gui \
--update-cache \
--language de,en \
--info-threads 24 \
--cache-valid 604800 \
--automatic-xml-creation \
--no-platform-detection \
--save-serials \
--save-changelogs \
--platform w,l \

# DOWNLOAD GAMES FROM GOG.COM
cd $GAME_DIR

lgogdownloader \
--download \
--use-cache \
--exclude patches \
--game '^(?!.*(hellblade_senuas_sacrifice_vr).*).*$' \ # Download games except games in brackets. Separate games in brackets with space.

# CHECK & DELETE ORPHANS
lgogdownloader --check-orphans > orphans.txt

xargs -a orphans.txt -d '\n' rm > /dev/null || { echo "No orphans found." ; }

rm orphans.txt
Post edited February 28, 2023 by Manu3110
avatar
Manu3110: what are unnecessary doublings in my script?
Well you certainly don't need to specify the directory. I'm not sure what advantage there is caching the game details. If it were me I'd just download a game like:

lgogdownloader --download --game chained_echoes --platform windows+linux --exclude patches,extras
Check Orphans Not Working?

I run the following command
lgogdownloader --check-orphans --verbose --directory /mnt/d/_gog_/_gog_downloads_ > orphans.txt

The results are

No orphaned files

But the attached screenshot sample directory of multiple versions.

I used this in the past to find and delete unwanted old versions.
Attachments:
Can't for the life of me figure out how to get around the Captcha login issue on my headless server.
CLI throws me this:

Login form contains reCAPTCHA but GUI login is disabled.
Enable GUI login with --enable-login-gui or try to login later.

I know I'm supposed to export a cookie and a json file (cookies.txt & galaxy_tokens.json), but I've only just now discovered that cookies aren't just txt files in your temporary internet files anymore like they used to be back on Windows 98.
Tried to mess around with a Firefox addon to get one exported, but I can't make anything work, running lgogdownloader just comes with the login and deletes the files.


Anyone know how I can work around this?
avatar
zahroc: Check Orphans Not Working?

I run the following command
lgogdownloader --check-orphans --verbose --directory /mnt/d/_gog_/_gog_downloads_ > orphans.txt

The results are

No orphaned files

But the attached screenshot sample directory of multiple versions.

I used this in the past to find and delete unwanted old versions.
I have not been able to reproduce this.
Orphan check seems to be working for me.

$ touch /media/GOG/tyrian_2000/orphaned_file_test.exe
$ lgogdownloader --check-orphans --game tyrian_2000 --directory /media/GOG/
Getting game names (3/3) 54 / 54
Getting game info 1 / 1
Checking for orphaned files 1 / 1
/media/GOG/tyrian_2000/orphaned_file_test.exe

There was an issue at some point when using implicit option values with boost program options.
Try --check-orphans '.*\.(zip|exe|bin|dmg|old|deb|tar\.gz|pkg|sh)$'
If that works then the issue is with the implicit option value.

avatar
epain: Can't for the life of me figure out how to get around the Captcha login issue on my headless server.
CLI throws me this:

Login form contains reCAPTCHA but GUI login is disabled.
Enable GUI login with --enable-login-gui or try to login later.

I know I'm supposed to export a cookie and a json file (cookies.txt & galaxy_tokens.json), but I've only just now discovered that cookies aren't just txt files in your temporary internet files anymore like they used to be back on Windows 98.
Tried to mess around with a Firefox addon to get one exported, but I can't make anything work, running lgogdownloader just comes with the login and deletes the files.

Anyone know how I can work around this?
I've just refactored the login code and made it possible to login using browser which might help in this situation

c26e28a Refactor login code

The login form seems to contain reCAPTCHA code even when it isn't used
The downloader should now always try to login normally using libcurl
If login using normal method fails and the downloader is built with -DUSE_QT_GUI=ON and --enable-login-gui option is used then login is performed using QtWebEngine
If GUI is not enabled and reCAPTCHA code is detected then user will be prompted to login using browser and copy & paste the full response url which the downloader uses to get auth code and complete the login using libcurl
Post edited March 12, 2023 by Sude
Hi guys

I got this to work on my Mac a few years ago. I just updated to a new machine and decided this time to fresh install rather than carry across a backup image that is now 12+ years old and everything has turned out well apart from lgogdownloader.

The version installed with brew doesn't want to log in:

Try to login later or compile LGOGDownloader with -DUSE_QT_GUI=ON

But there isn't a source for Mac listed for me to compile with that additional flag - just a bunch of Linux distributions.

Does anyone know which of those is the best to use with a Mac? And are there any changes required?

Yes I know not many games are available for Mac. I have a Mac as a daily and a Windows games machine, but since I'm on the Mac daily, that's where I would run my GOG update script.

I do have a backup of ~/user/.cache/lgogdownloader and ~/user/.config/lgogdownloader and I was hoping these would have the required credentials saved but sadly that doesn't seem to be the case. :(

I can't find any other matches from the searches I've tried but if anyone knows where I might be able to get those cached session details, or how to get a version of the app that can log in and create a new session, that would be much appreciated.

Thanks in advance for any tips!
Post edited March 13, 2023 by g4r37h
avatar
epain: Can't for the life of me figure out how to get around the Captcha login issue on my headless server.
CLI throws me this:

Login form contains reCAPTCHA but GUI login is disabled.
Enable GUI login with --enable-login-gui or try to login later.

I know I'm supposed to export a cookie and a json file (cookies.txt & galaxy_tokens.json), but I've only just now discovered that cookies aren't just txt files in your temporary internet files anymore like they used to be back on Windows 98.
Tried to mess around with a Firefox addon to get one exported, but I can't make anything work, running lgogdownloader just comes with the login and deletes the files.

Anyone know how I can work around this?
avatar
Sude: I've just refactored the login code and made it possible to login using browser which might help in this situation

c26e28a Refactor login code

The login form seems to contain reCAPTCHA code even when it isn't used
The downloader should now always try to login normally using libcurl
If login using normal method fails and the downloader is built with -DUSE_QT_GUI=ON and --enable-login-gui option is used then login is performed using QtWebEngine
If GUI is not enabled and reCAPTCHA code is detected then user will be prompted to login using browser and copy & paste the full response url which the downloader uses to get auth code and complete the login using libcurl
Ah awesome, thanks for the swift response!
Will this commit be part of an upcoming release? Then I'll just wait for it to arrive through my package manager :)
Further to my earlier post, I'm trying to build from source for Mac. I've reached here:

ninja: error: '/opt/homebrew/lib/libhtmlcxx.dylib', needed by 'lgogdownloader', missing and no known rule to make it

Unlike all the other dependencies up to this point, I don't seem to be able to find a Mac equivalent of libhtmlcxx-dev.

I know I didn't have to do any of this last time I got it running on my Mac though. I just wish I remembered exactly how I got it running. :/

I've tried temporarily disabling 2FA but the bew installation of lgogdownloader it still complains about reCAPCHA.

Any ideas why the brew version doesn't seem to be compiled with -DUSE_QT_GUI=ON? It seems to be a breaking requirement.
Post edited March 14, 2023 by g4r37h
Well, there's not much support in here so I've gone ahead and switched to gogcli instead. I got that up and running in less than 10 minutes and it's currently downloading and parsing my manifest.

All the best to those who continue to wrestle with lgogdownloader workarounds!
Can I download (single or in bulk mode) purchase receipts via LGOGdownloader?
Also, what's the command to resume interrupted downloads? Thnks
avatar
g4r37h: Well, there's not much support in here so I've gone ahead and switched to gogcli instead. I got that up and running in less than 10 minutes and it's currently downloading and parsing my manifest.

All the best to those who continue to wrestle with lgogdownloader workarounds!
Entitled much?
LGOGDownloader 3.10
- Added support for cloud saves (Patch by: loki-47-6F-64)
- Added initial support for ignoring DLCs with --galaxy-install
* Supports ignoring all DLCs when installing game with --galaxy-install
- Fixed MojoSetup hack for files that have missing XML data
* Tries to get file size using Content-Length header if XML data is missing
- Extended global flag bSizeOnly into status text generation (Patch by: Gordon)
- Added option to set message verbosity level
* Replaced --verbose option with --verbosity to better control message verbosity
- Fixed core dump with libcurl >= 7.87.0
- Slightly nicer libcurl cleanup (Patch by: David Donátek)
- Don't use depracated libcurl options
- Refactored login code
* Users can now get around reCATPCHA without the downloader being built with GUI enabled by using their browser to login
- Removed --list-details option
- Removed --list-tags option
- Changed --list option so it can be used to select what info to print
* "games" is the same as --list previously
* "details" is the same as --list-details previously
* "json" is JSON formatted output
* "tags" is the same as --list-tags previously
* The default implicit value is "games" (meaning --list is the same as --list "games")
- Remove make dependency on grep and readelf
* These were not actually needed since support for OpenSSL <= 1.0.2 was removed in version 3.9 but I forgot to remove the requirement at the time

https://github.com/Sude-/lgogdownloader/releases/download/v3.10/lgogdownloader-3.10.tar.gz

sha256: eb91778cb1395884922e32df8ee15541eaccb06d75269f37fd228306557757ca
md5: d8f22c8e1d7b711fc318b9d8c271c033

There have been lots of changes to options so it's probably a good idea to list all of them here
Removed options:
--list-details
--list-tags
--verbose

Added options:
--verbosity
--galaxy-download-cloud-saves
--galaxy-upload-cloud-saves
--galaxy-show-cloud-saves
--galaxy-show-local-cloud-saves
--galaxy-delete-cloud-saves

Changed options:
--list
avatar
Sude: * Supports ignoring all DLCs when installing game with --galaxy-install
What's the scenario where someone would do a galaxy install on Linux?
avatar
zahroc: Check Orphans Not Working?

I run the following command
lgogdownloader --check-orphans --verbose --directory /mnt/d/_gog_/_gog_downloads_ > orphans.txt

The results are

No orphaned files

But the attached screenshot sample directory of multiple versions.

I used this in the past to find and delete unwanted old versions.
avatar
Sude: I have not been able to reproduce this.
Orphan check seems to be working for me.

$ touch /media/GOG/tyrian_2000/orphaned_file_test.exe
$ lgogdownloader --check-orphans --game tyrian_2000 --directory /media/GOG/
Getting game names (3/3) 54 / 54
Getting game info 1 / 1
Checking for orphaned files 1 / 1
/media/GOG/tyrian_2000/orphaned_file_test.exe

There was an issue at some point when using implicit option values with boost program options.
Try --check-orphans '.*\.(zip|exe|bin|dmg|old|deb|tar\.gz|pkg|sh)$'
If that works then the issue is with the implicit option value.
Neither worked.

wsluser@LAPTOP-T540:~/lgogdownloader/build$ lgogdownloader --check-orphans --game the_witcher_3_wild_hunt_game_of_the_year_edition_game --directory /mnt/d/_gog_/_gog_downloads_
Getting game names (5/5) 82 / 82
Getting game info 1 / 1
Checking for orphaned files 1 / 1
No orphaned files

wsluser@LAPTOP-T540:~/lgogdownloader/build$ lgogdownloader --check-orphans '.*\.(zip|exe|bin|dmg|old|deb|tar\.gz|pkg|sh)$' --game the_witcher_3_wild_hunt_game_of_the_year_edition_game --directory /mnt/d/_gog_/_gog_downloads_
Getting game names (5/5) 82 / 82
Getting game info 1 / 1
Checking for orphaned files 1 / 1
No orphaned files

Here is the directory listing attached
Attachments:
Post edited March 16, 2023 by zahroc