public void InstallUpdate() { var portable = PlayniteSettings.IsPortable ? "/PORTABLE" : ""; logger.Info("Installing new update to {0}, in {1} mode", PlaynitePaths.ProgramPath, portable); playniteApp.QuitAndStart( updaterPath, string.Format(@"/SILENT /NOCANCEL /DIR=""{0}"" /UPDATE {1}", PlaynitePaths.ProgramPath, portable), !FileSystem.CanWriteToFolder(PlaynitePaths.ProgramPath)); }
public void InstallUpdate(ApplicationMode mode) { var portable = PlayniteSettings.IsPortable ? "/PORTABLE" : ""; var fullscreen = mode == ApplicationMode.Fullscreen ? "/FULLSCREEN" : ""; logger.Info("Installing new update to {0}, in {1} mode".Format(PlaynitePaths.ProgramPath, portable)); playniteApp.QuitAndStart( updaterPath, @"/SILENT /NOCANCEL /DIR=""{0}"" /UPDATE {1} {2}".Format(PlaynitePaths.ProgramPath, portable, fullscreen), !FileSystem.CanWriteToFolder(PlaynitePaths.ProgramPath)); }
public void InstallUpdate() { var portable = PlayniteSettings.IsPortable ? "/PORTABLE" : ""; logger.Info("Installing new update to {0}, in {1} mode", PlaynitePaths.ProgramPath, portable); Task.Run(() => { var args = string.Format(@"/SILENT /NOCANCEL /DIR=""{0}"" /UPDATE {1}", PlaynitePaths.ProgramPath, portable); if (FileSystem.CanWriteToFolder(PlaynitePaths.ProgramPath)) { ProcessStarter.StartProcess(updaterPath, args); } else { ProcessStarter.StartProcess(updaterPath, args, true); } }); playniteApp.Quit(); }