Forgot to rename things, doh!

This commit is contained in:
Peter Taylor 2022-03-09 11:32:17 +00:00
parent a82598759c
commit 16446fef7e
5 changed files with 11 additions and 11 deletions

View file

@ -1,11 +1,11 @@
from getpass import getpass
import itchio
import itchiodl
user = input("Username: ")
password = getpass("Password: ")
l = itchio.LoginWeb(user, password)
l = itchiodl.LoginWeb(user, password)
url = input("Bundle URL: ")
b = itchio.Bundle(l, url)
b = itchiodl.Bundle(l, url)
b.load_games()

View file

@ -1,7 +1,7 @@
import argparse
from getpass import getpass
import itchio
import itchiodl
parser = argparse.ArgumentParser(
prog='python -m hstp',
@ -17,10 +17,10 @@ l = ""
if not args.api_key:
user = input("Username: ")
password = getpass("Password: ")
l = itchio.LoginAPI(user, password)
l = itchiodl.LoginAPI(user, password)
else:
l = args.api_key
lib = itchio.Library(l)
lib = itchiodl.Library(l)
lib.load_games()
lib.download_library()

View file

@ -6,7 +6,7 @@ import urllib
import itchio.utils
import itchiodl.utils
class Game:
def __init__(self, data):
@ -59,8 +59,8 @@ class Game:
url = f"https://api.itch.io/uploads/{d['id']}/download?api_key={token}&download_key_id={self.id}&uuid={j['uuid']}"
# response_code = urllib.request.urlopen(url).getcode()
try:
itchio.utils.download(url, path, self.name +" - "+file)
except itchio.utils.NoDownloadError as e:
itchiodl.utils.download(url, path, self.name +" - "+file)
except itchiodl.utils.NoDownloadError as e:
print("Http response is not a download, skipping")
with open('errors.txt', 'a') as f:

View file

@ -1,7 +1,7 @@
import requests
import json
from itchio.game import Game
from itchiodl.game import Game
class Library:
def __init__(self, login):

View file

@ -1,6 +1,6 @@
[tool.poetry]
name = "itchiodl"
version = "1.1.1"
version = "1.1.2"
description = "Python Scripts for downloading / archiving your itchio library"
authors = ["Peter Taylor <me@et1.uk>"]
license = "MIT"