Commit 3c0d05a9 authored by echel0n's avatar echel0n

Source updates now download and unpack to main program folder to resolve update issues.

parent 3151280c
# Changelog
- * db4354e - 2019-03-04: Cleaned up backup and restore functions for database. Bumped keycloak requirement to v0.2.2
- * 682b983 - 2019-03-04: Source updates now download and unpack to main program folder to resolve update issues.
- * 3151280 - 2019-03-04: Cleaned up backup and restore functions for database. Bumped keycloak requirement to v0.2.2
- * fe70b17 - 2019-03-03: Added backup and restore functions to database class. Refactored backup and restore system for app to accommodate for migration to python 3.
- * a72ca25 - 2019-02-24: Release v9.4.77
- * b09d78a - 2019-02-24: Added Anime regex for Erai-raws
......
......@@ -606,7 +606,7 @@ class SourceUpdateManager(UpdateManager):
try:
# prepare the update dir
sr_update_dir = os.path.join(sickrage.app.data_dir, 'sr-update')
sr_update_dir = os.path.join(sickrage.PROG_DIR, 'sr-update')
if os.path.isdir(sr_update_dir):
sickrage.app.log.info("Clearing out update folder " + sr_update_dir + " before extracting")
......@@ -653,12 +653,12 @@ class SourceUpdateManager(UpdateManager):
# walk temp folder and move files to main folder
content_dir = os.path.join(sr_update_dir, update_dir_contents[0])
sickrage.app.log.info("Moving files from " + content_dir + " to " + sickrage.MAIN_DIR)
sickrage.app.log.info("Moving files from " + content_dir + " to " + sickrage.PROG_DIR)
for dirname, __, filenames in os.walk(content_dir):
dirname = dirname[len(content_dir) + 1:]
for curfile in filenames:
old_path = os.path.join(content_dir, dirname, curfile)
new_path = os.path.join(sickrage.MAIN_DIR, dirname, curfile)
new_path = os.path.join(sickrage.PROG_DIR, dirname, curfile)
if os.path.isfile(new_path) and os.path.exists(new_path):
os.remove(new_path)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment