diff options
| author | Eric Reed <ebr@mediabrowser3.com> | 2013-03-13 17:52:56 -0400 |
|---|---|---|
| committer | Eric Reed <ebr@mediabrowser3.com> | 2013-03-13 17:52:56 -0400 |
| commit | 2f64303dcdc3c0a550c66c16584d330bf8c3c174 (patch) | |
| tree | 3dd0355699e84c4b2e238f5adaf51ed20d99750e /MediaBrowser.Common.Implementations/Updates | |
| parent | 1e0a405ef39cc45654b4882546f22d27630399a3 (diff) | |
Attempt to fix in-place updates #52
Diffstat (limited to 'MediaBrowser.Common.Implementations/Updates')
| -rw-r--r-- | MediaBrowser.Common.Implementations/Updates/ApplicationUpdater.cs | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/MediaBrowser.Common.Implementations/Updates/ApplicationUpdater.cs b/MediaBrowser.Common.Implementations/Updates/ApplicationUpdater.cs index 7ab5745474..9dc0eb85c8 100644 --- a/MediaBrowser.Common.Implementations/Updates/ApplicationUpdater.cs +++ b/MediaBrowser.Common.Implementations/Updates/ApplicationUpdater.cs @@ -21,10 +21,15 @@ namespace MediaBrowser.Common.Implementations.Updates // Use our installer passing it the specific archive // We need to copy to a temp directory and execute it there var source = Path.Combine(appPaths.ProgramSystemPath, UpdaterExe); - var target = Path.Combine(Path.GetTempPath(), UpdaterExe); + var tempUpdater = Path.Combine(Path.GetTempPath(), UpdaterExe); var product = app == MBApplication.MBTheater ? "mbt" : "server"; - File.Copy(source, target, true); - Process.Start(target, string.Format("product={0} archive=\"{1}\" caller={2} pismo=false", product, archive, Process.GetCurrentProcess().Id)); + File.Copy(source, tempUpdater, true); + // Our updater needs SS and ionic + source = Path.Combine(appPaths.ProgramSystemPath, "ServiceStack.Text.dll"); + File.Copy(source, Path.Combine(Path.GetTempPath(), "ServiceStack.Text.dll"), true); + source = Path.Combine(appPaths.ProgramSystemPath, "Ionic.Zip.dll"); + File.Copy(source, Path.Combine(Path.GetTempPath(), "Ionic.Zip.dll"), true); + Process.Start(tempUpdater, string.Format("product={0} archive=\"{1}\" caller={2} pismo=false", product, archive, Process.GetCurrentProcess().Id)); // That's it. The installer will do the work once we exit } |
