mirror of
https://github.com/lidarr/lidarr.git
synced 2025-07-16 10:03:51 -07:00
First round of refactoring.
This commit is contained in:
parent
c98c679504
commit
20c8dec50a
117 changed files with 283 additions and 261 deletions
|
@ -1,4 +1,4 @@
|
|||
using System;
|
||||
using System;
|
||||
using System.IO;
|
||||
using NLog;
|
||||
using NzbDrone.Common.Disk;
|
||||
|
@ -80,7 +80,7 @@ namespace NzbDrone.Update.UpdateEngine
|
|||
public void Start(string installationFolder, int processId)
|
||||
{
|
||||
_logger.Info("Installation Folder: {0}", installationFolder);
|
||||
_logger.Info("Updating Sonarr from version {0} to version {1}", _detectExistingVersion.GetExistingVersion(installationFolder), BuildInfo.Version);
|
||||
_logger.Info("Updating Lidarr from version {0} to version {1}", _detectExistingVersion.GetExistingVersion(installationFolder), BuildInfo.Version);
|
||||
|
||||
Verify(installationFolder, processId);
|
||||
|
||||
|
@ -103,7 +103,7 @@ namespace NzbDrone.Update.UpdateEngine
|
|||
{
|
||||
if (_processProvider.Exists(ProcessProvider.NZB_DRONE_CONSOLE_PROCESS_NAME) || _processProvider.Exists(ProcessProvider.NZB_DRONE_PROCESS_NAME))
|
||||
{
|
||||
_logger.Error("Sonarr was restarted prematurely by external process.");
|
||||
_logger.Error("Lidarr was restarted prematurely by external process.");
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
@ -116,10 +116,10 @@ namespace NzbDrone.Update.UpdateEngine
|
|||
_logger.Info("Copying new files to target folder");
|
||||
_diskTransferService.MirrorFolder(_appFolderInfo.GetUpdatePackageFolder(), installationFolder);
|
||||
|
||||
// Set executable flag on Sonarr app
|
||||
// Set executable flag on Lidarr app
|
||||
if (OsInfo.IsOsx)
|
||||
{
|
||||
_diskProvider.SetPermissions(Path.Combine(installationFolder, "Sonarr"), "0755", null, null);
|
||||
_diskProvider.SetPermissions(Path.Combine(installationFolder, "Lidarr"), "0755", null, null);
|
||||
}
|
||||
}
|
||||
catch (Exception e)
|
||||
|
@ -146,7 +146,7 @@ namespace NzbDrone.Update.UpdateEngine
|
|||
|
||||
if (_processProvider.Exists(ProcessProvider.NZB_DRONE_PROCESS_NAME))
|
||||
{
|
||||
_logger.Info("Sonarr was restarted by external process.");
|
||||
_logger.Info("Lidarr was restarted by external process.");
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue