Author | SHA1 | Message | Date |
---|---|---|---|
sharky555 | 61297351ea |
Merge pull request 'fix issue 3 and 4' (#5) from issue3and4 into master
Reviewed-on: https://git.sugoimusic.me/sharky555/SM-AU-TV/pulls/5 |
3 years ago |
sharky555 | 5928ac942b | Merge branch 'master' into issue3and4 | 3 years ago |
sharky555 | 38a1dfb9e9 | fix issue 3 and 4 | 3 years ago |
@@ -34,8 +34,8 @@ Command | Description | |||||
-ey [EDITIONYEAR], --year [EDITIONYEAR] | Set the edition year (YYYYMMDD or YYYY). | -ey [EDITIONYEAR], --year [EDITIONYEAR] | Set the edition year (YYYYMMDD or YYYY). | ||||
-im [IMAGEURL], --imageURL [IMAGEURL] | Set the torrent cover URL. | -im [IMAGEURL], --imageURL [IMAGEURL] | Set the torrent cover URL. | ||||
-ss [SCREENSHOTURLS], --screenshots [SCREENSHOTURLS] | Set the screenshot URLs. Split multiple with "," | -ss [SCREENSHOTURLS], --screenshots [SCREENSHOTURLS] | Set the screenshot URLs. Split multiple with "," | ||||
-tdes [TORRENTDESCRIPTION], --description [TORRENTDESCRIPTION] | Add a torrent description. Only available as an argument. | |||||
-tgdes [TORRENTGROUPDESCRIPTION], --description [TORRENTGROUPDESCRIPTION] | Add a torrent group description. This must be added as an argument. | |||||
-tdes [TORRENTDESCRIPTION], --torrentdescription [TORRENTDESCRIPTION] | Add a torrent description. Only available as an argument. | |||||
-tgdes [TORRENTGROUPDESCRIPTION], --torrentgroupdescription [TORRENTGROUPDESCRIPTION] | Add a torrent group description. This must be added as an argument. | |||||
## Config.json | ## Config.json | ||||
@@ -1 +1 @@ | |||||
python upload.py -i "C:\path to file" --releasetype "PV" --artists "" --title "" --tags "" --year "" --mediasource "HDTV" --sub "NoSubs" --language "Japanese" --imageurl "" --torrentgroupdescription "a long description!!!!" | |||||
python upload.py -i "C:\path to file" --releasetype "PV" --artists "" --title "" --tags "" --year "" --mediasource "HDTV" --sub "NoSubs" --language "Japanese" --imageURL "" --torrentgroupdescription "a long description!!!!" |
@@ -402,7 +402,7 @@ def uploadtorrent(torrent, imageURL, releasedata): | |||||
## TODO Filter through JPSres.text and create error handling based on responses | ## TODO Filter through JPSres.text and create error handling based on responses | ||||
#print(JPSres.text) | #print(JPSres.text) | ||||
def localfileorganization(torrent, directory, watch_folder, downloads_folder): | |||||
def localfileorganization(torrent, watch_folder): | |||||
# Move torrent directory to downloads_folder | # Move torrent directory to downloads_folder | ||||
# if cfg['local_prefs']['add_to_downloads_folder']: | # if cfg['local_prefs']['add_to_downloads_folder']: | ||||
# try: | # try: | ||||
@@ -508,8 +508,8 @@ if __name__ == "__main__": | |||||
# local_downloads_folder = cfg['local_prefs']['local_downloads_folder'] | # local_downloads_folder = cfg['local_prefs']['local_downloads_folder'] | ||||
if not dryrun: | if not dryrun: | ||||
if cfg['local_prefs']['add_to_watch_folder'] or cfg['local_prefs']['add_to_downloads_folder']: | |||||
localfileorganization(torrent=torrentfile, watch_folder=local_watch_folder) | |||||
if cfg['local_prefs']['add_to_watch_folder']: | |||||
os.rename(torrentfile, f"{local_watch_folder}/{torrentfile}") | |||||