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

×
I'd like to save the installers and extras of all the games I own on GOG to an external drive, but I have no idea of their total size, plus it would be a real pain to dowload all the files manually.
I need to automate the procedure and my only chance, as far as I can tell, is to use gogrepo - problem is, I don't know anything about Python and I don't know how to operate the script.
I have installed Python on my computer and that is as far as I can go on my own; next step, I reckon, would be to install html5lib and html2text, but I have no idea how to do that. Then, I'll have to learn to use the script itself.
I would be very grateful if someone stopped by and gave me some step-by-step instruction on how to proceed.
I do apologise if this thread can be seen as redundant; I searched for information on the forum beforehand, but what I found seemed to presuppose a degree of confidence with the subject-matter that unfortunately I do not possess.
Hopefully, the hints provided here could prove useful for others with the same need in the future.
This question / problem has been solved by timppuimage
I'm not sure if it's the ideal method, but since I'm more used with Linux's commands and folder structure, when I want to use gogrepo on Windows, I use Windows Subsystem for Linux (WSL) with Python 3 installed in it.

Go to the folder where gogrepo.py is > Shift right click > open WSL here > type the command > wait for the process to finish

Mind WSL seems to have issues when it has to write over a file that has symbols in it, e.g "!", and gogrepo generates a file with that symbol in the name every time it downloads a game, so in the second time you download the same game without moving the previous files somewhere else in advance, the script will break. This issue doesn't seem to happen in native Linux installs.

After having gogrepo set up, I run this command whenever I want to download a new game I got or a game that got a new update:
python3 gogrepo.py update -os windows linux mac -lang en bl ru gk sb ar br jp ko fr cn cz hu pt tr sk nl ro es pl it de da sv fi no -id id of the game ; python3 gogrepo.py download -id id of the game
The id of the game is usually what appears at the end of the link of the game's store page (base game when available). Check your library to confirm each game's store link. Mind some games have weird ids, like games that come in packages (e.g. both versions of Agony). Both ids need to be from the same game.

And you can repeat this command in a single run for as many titles as you want. You just need to put a ; between each command and get the right id for each game.
I wrote the procedure a lot of times, you should check the gogrepo thread.
But if you really need help, send me a PM.
Post edited December 12, 2021 by phaolo
So I found out about the "GOGcli GUI" program made by GOGer Timboli, and I have to say, it seems just like what I needed.
It doesn't require Python and I find it much simpler to use. I therefore choose that over gogrepo.
Thank you all the same.

PS
I know there is also a "GOGrepo GUI" by the same user. I tried that as well but I wasn't able to make it work. I had trouble with pip: I wasn't able to install it using "get-pip.py" (this one) and I have no idea how to install html5lib without it.
Maybe if gogrepo supported Python 3 (which comes with pip by default) I could have managed to make it work.
However I'm talking about things I have a very vague understanding of. Thread closed.
avatar
cose_vecchie: I know there is also a "GOGrepo GUI" by the same user. I tried that as well but I wasn't able to make it work. I had trouble with pip: I wasn't able to install it using "get-pip.py" (this one) and I have no idea how to install html5lib without it.
Maybe if gogrepo supported Python 3 (which comes with pip by default) I could have managed to make it work.
However I'm talking about things I have a very vague understanding of. Thread closed.
Maybe the readme file of gogrepo is out of date, but you SHOULD use python 3 with it. I am not sure if it even supports python 2 anymore.

Hopefully you were trying the Kalanyr version of gogrepo, e.g. this:

https://github.com/Kalanyr/gogrepoc

Here are some quick instructions on using gogrepo on Windows (hopefully I got them right):

1. Download and install Python 3.x.x from https://www.python.org/downloads/

- When you install it, make sure to tick the box for letting Python to be added to the PATH, so that you can run python scripts easily anywhere in your filesystem.

2. Get gogrepo from https://github.com/Kalanyr/gogrepoc

- Click on the "Clone"-button and select "Download ZIP", and then uncompress the zip file to a suitable place in your computer, e.g. C:\gogrepo\. There should be a subfolder "gogrepo-master" (or similar) where you have the gogrepo.py script.

- For simplicity's sake, put gogrepo to the drive where you think you have enough room for your GOG game installers you are going to download. However, there are also options to download your installers to any other drives or paths.

3. Run preliminary things for gogrepo

- Open the command prompt (press the Windows key + R and type cmd) and give these commands:

pip install html5lib
pip install html2text
pip install six
pip install requests
pip install pyopenssl

cd \gogrepo\gogrepoc-master (or in whichever folder you uncompressed the gogrepo.py script)

Note: before running the following (login) command, it may be advisable to make sure you are able to log into your GOG account with a web browser from that very same computer (IP address). That way the two-factor authentication shouldn't kick in in the next command because gog.com sees you have already successfully logged into your account before from that same IP address:

python gogrepoc.py login

Follow the instructions, if you have two-step login enabled, you have to get the verification code from your email and enter it here. This login needs to be done only once, in order to get valid login cookies ("gog-cookies.dat") for gogrepo.

4. Run gogrepo.

In the command prompt, in the directory where the gogrepo.py is (e.g. c:\gogrepo\gogrepo-master\), you can run e.g. these commands:

python gogrepoc.py update -lang en -os windows

This step can take many hours, depending how many games you have in your account. It creates the gog-manifest.dat file including the details for all your GOG game files, in this example for English language Windows versions of games only. If you want some other language versions as well, I think these are the known language options: en cz da de es fr it hu nl no pl pt br ro fi sv tr ru ko cn jp

python gogrepoc.py download -dryrun D:\goggames\

This will not download anything, but only simulate it. With it you can see how much data is to be downloaded.
After that you can run the proper download command:

python gogrepoc.py download D:\goggames\

Replace "D:\goggames\" where you want to download your games. Naturally the directory must exist already.

Two additional commands you might want to try:

python gogrepo.py clean D:\goggames\

That will move any obsolete files into the !orphaned directory, from which you can delete (or keep) them at will.

python gogrepo.py verify D:\goggames\

That will verify that your downloaded files are ok (correct md5 checksums, and zip files pass the integrity check).

==============

Then next time you want to check and download for any new or updated files, run update/download/clean/verify again, rinse and repeat.
Post edited December 13, 2021 by timppu
avatar
timppu: Maybe the readme file of gogrepo is out of date, but you SHOULD use python 3 with it. I am not sure if it even supports python 2 anymore.
Hopefully you were trying the Kalanyr version of gogrepo
Well... actually, no. At first, I was blissfully unaware of the Kalanyr version... I used the eddie3 version, downloaded from here - and that, in turn, prompted me to use Python 2.7, since the description literally reads "It requires a typical Python 2.7 installation" and, in the "Requirements" section below, you find: "Python 2.7 (Python 3 support coming soon)".
...out of date indeed!
In the end, I think I can say that all my troubles sprang from using such an old version of Python. Switching to a newer version solved my problems, allowing me to install the required libraries. Now everything seems to be in working order.
I had decided to declare the thread closed because I was tired of struggling to make things work and I hadn't got a clue what to try next. My understanding of Python is still pretty vague... but thank you a lot for offering to help nonetheless.