Hi,
I write a script that use an OpenBSD-games-database (
https://github.com/playonbsd/OpenBSD-Games-Database) and retrieves informations about that games from GOG.com. Launch the script with
Code:
$./pobsdvgof.0.4.sh
with the option -r (rate and count values, ie how many people voted and their rating), -d (date of the end of promo for sales games), -a (for all this informations), -g game (one game), -l (list with one game per line). I notice that "-ga" or "-g a" will retrieve all games and the output is in the terminal.
Informations are saved in files, or show in terminal for one game and for the option "-ga" or "g a" also.
The script produces and deletes files so I advice to put it in a own directory.
The script takes time as it can retrieve 141 games (on GOG.com).
Code:
$ time ./pobsdvgof.0.4.sh
4m39.08s real 0m22.26s user 0m24.79s system
One game is fast, for a list of 8 games:
Code:
time ./pobsdvgof_0.4.sh -l my_list_gog_game
0m11.69s real 0m01.79s user 0m02.07s system
This script use sed, gsed, awk, curl, I write it in ksh language.
I tried a different script with steam and humblebundle games, not so evolve as this one. A script with steam games requires a different code + there is restriction age for some games that I can not know how to go through with curl. With humblebundle I do not know how to retrieve the sale value in the html code as it seems not to appear.
You can add a "-s" to curl to make it silence.
It is an experience and learning.
Enjoy and of course I am not responsible if it break your system!