about summary refs log tree commit diff
path: root/pkgs/games/humblebundle/fetch-humble-bundle
Commit message (Collapse)AuthorAgeFilesLines
* pkgs/games: Fix fetchHumbleBundleaszlig2017-09-131-0/+4
| | | | | | | | | The login URL for HumbleBundle has changed from /login to /processlogin, so let's fix it quickly via sed. Signed-off-by: aszlig <aszlig@redmoonstudios.org> Issue: saik0/humblebundle-python#16 Cc: @saik0
* pkgs/fetch-humble-bundle: s/requests2/requests/aszlig2017-06-161-1/+1
| | | | | | | The requests2 package has been merged into the original project upstream and thus is deprecated. Signed-off-by: aszlig <aszlig@redmoonstudios.org>
* humble-bundle: Add helper for solving captchasaszlig2017-06-091-2/+96
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is not only a major annoyance for us but seems to bother a few other people using the humblebundle-python API: * saik0/humblebundle-python#11 * saik0/humblebundle-python#14 * saik0/humblebundle-python#15 While digging through the reCaptcha2 API and also the implementation of the Humble Bundle site, I stumbled over this code from https://www.humblebundle.com/user/captcha: var captcha = new Recaptcha2('captcha-holder'); $('input[type=submit]').click(function(e){ e.preventDefault(); // recaptcha v2 only cares about response, but we can let the Android app interface stay the same var challenge = ''; var response = captcha.get_response(); var android_defined = false; if (typeof Android != 'undefined') { Android.setCaptchaResponse(challenge, response); } }) So we only need the response, which we do now using a very ugly written Qt 5 QWebEngine GUI which we use to ask the user to solve the captcha. Combined with our downloader, it works like this: Whenever the login fails with a HumbleCaptchaException, we print a message with the store path to the GUI helper. We're inside a fixed-output derivation builder, so we do have networking. The GUI helper also runs a small TCP server listening on port 18123 and the downloader inside the Nix builder constantly tries to connect to that port and waits until it gets just one string (the connection is directly closed afterwards and the GUI helper exits), which is the response. This is then passed as recaptcha_response keyword argument to the login() method of the HumbleApi object. Signed-off-by: aszlig <aszlig@redmoonstudios.org>
* Revert "runCommand -> runCommandCC"aszlig2016-10-171-14/+2
| | | | | | | | | | | | | This reverts commit e3f8d28d6be67257d70035d122263f3a35adc438 and my attempts to mitigate this in 0a50f5fab1abf2e70fd5d7a2dd717c2f2c1b983b and 3b91f25b37ea709f5c86e38a50061199bbed5341. Vuizvui is a repository for experimental stuff, but NOT a dumpster. So please refrain from pushing waste into this repository, like markers for a failed merge. Signed-off-by: aszlig <aszlig@redmoonstudios.org> Cc: @Profpatsch
* runCommand -> runCommandCCProfpatsch2016-10-151-2/+14
|
* pkgs: Switch to pythonPackages.buildPythonPackageaszlig2016-09-271-2/+2
| | | | | | | Since 771ed59b48bc1257439b4529426cc9047aebc27b, there is no top-level attribute anymore, so let's fix this. Signed-off-by: aszlig <aszlig@redmoonstudios.org>
* fetch-humble-bundle: Allow single-output curlaszlig2016-08-161-1/+2
| | | | | | | This should make sure it can be evaluated on NixOS versions where the closure-size branch has not yet been merged. Signed-off-by: aszlig <aszlig@redmoonstudios.org>
* games/fetch-humble-bundle: Fix path to curlaszlig2016-06-041-1/+1
| | | | | | | Since the merge of the closure-size branch, the curl binary now is in a dedicated output ".bin". Signed-off-by: aszlig <aszlig@redmoonstudios.org>
* Merge aszlig/nixgames into vuizvuiaszlig2016-02-081-0/+87
This is a subtree merge of the full nixgames repository including history. Right now it isn't linked to vuizvui at all but we're going to do that very soon. The reason why I'm merging both repositories together is that it's easier for me to manage updates and also facilitate contributions by people from the OpenLab. Another reason to merge it is that we can write more generic functions for building both, the games and the rest. Right now the licensing is still the Apache License version 2.0, but we're going to change it to the vuizvui license as well.