Merge branch 'refs/heads/develop'
This commit is contained in:
@@ -21,7 +21,9 @@ class Updater(Plugin):
|
|||||||
|
|
||||||
def __init__(self):
|
def __init__(self):
|
||||||
|
|
||||||
if os.path.isdir(os.path.join(Env.get('app_dir'), '.git')):
|
if Env.get('desktop'):
|
||||||
|
self.updater = DesktopUpdater()
|
||||||
|
elif os.path.isdir(os.path.join(Env.get('app_dir'), '.git')):
|
||||||
self.updater = GitUpdater(self.conf('git_command', default = 'git'))
|
self.updater = GitUpdater(self.conf('git_command', default = 'git'))
|
||||||
else:
|
else:
|
||||||
self.updater = SourceUpdater()
|
self.updater = SourceUpdater()
|
||||||
@@ -334,3 +336,32 @@ class SourceUpdater(BaseUpdater):
|
|||||||
log.error('Failed getting latest request from github: %s' % traceback.format_exc())
|
log.error('Failed getting latest request from github: %s' % traceback.format_exc())
|
||||||
|
|
||||||
return {}
|
return {}
|
||||||
|
|
||||||
|
|
||||||
|
class DesktopUpdater(Plugin):
|
||||||
|
|
||||||
|
version = None
|
||||||
|
update_failed = False
|
||||||
|
update_version = None
|
||||||
|
last_check = 0
|
||||||
|
|
||||||
|
def __init__(self):
|
||||||
|
self.desktop = Env.get('desktop')
|
||||||
|
|
||||||
|
def doUpdate(self):
|
||||||
|
pass
|
||||||
|
|
||||||
|
def info(self):
|
||||||
|
return {
|
||||||
|
'last_check': self.last_check,
|
||||||
|
'update_version': self.update_version,
|
||||||
|
'version': self.getVersion(),
|
||||||
|
'branch': 'desktop_build',
|
||||||
|
}
|
||||||
|
|
||||||
|
def check(self):
|
||||||
|
pass
|
||||||
|
|
||||||
|
def getVersion(self):
|
||||||
|
return {}
|
||||||
|
|
||||||
|
|||||||
@@ -45,7 +45,7 @@ class Renamer(Plugin):
|
|||||||
return
|
return
|
||||||
|
|
||||||
if self.renaming_started is True:
|
if self.renaming_started is True:
|
||||||
log.error('Renamer is disabled to avoid infinite looping of the same error.')
|
log.info('Renamer is disabled to avoid infinite looping of the same error.')
|
||||||
return
|
return
|
||||||
|
|
||||||
# Check to see if the "to" folder is inside the "from" folder.
|
# Check to see if the "to" folder is inside the "from" folder.
|
||||||
@@ -322,8 +322,6 @@ class Renamer(Plugin):
|
|||||||
elif not remove_leftovers: # Don't remove anything
|
elif not remove_leftovers: # Don't remove anything
|
||||||
remove_files = []
|
remove_files = []
|
||||||
|
|
||||||
continue
|
|
||||||
|
|
||||||
# Rename all files marked
|
# Rename all files marked
|
||||||
group['renamed_files'] = []
|
group['renamed_files'] = []
|
||||||
for src in rename_files:
|
for src in rename_files:
|
||||||
|
|||||||
Reference in New Issue
Block a user