WIP 2 on the Updater. Updater.exe won't boot now for some reason...
This commit is contained in:
parent
402c3a0154
commit
b756d61292
5 changed files with 15 additions and 8 deletions
|
@ -72,6 +72,8 @@ namespace Ryujinx.Updater
|
|||
versionNumber = metaFileData[0];
|
||||
downloadUrl = metaFileData[1];
|
||||
|
||||
MessageBox.Show(downloadUrl);
|
||||
|
||||
using (WebClient client = new WebClient())
|
||||
{
|
||||
client.DownloadFile(downloadUrl, updateSaveLocation);
|
||||
|
|
|
@ -1,10 +1,10 @@
|
|||
<Project Sdk="Microsoft.NET.Sdk.WindowsDesktop">
|
||||
|
||||
<PropertyGroup>
|
||||
<OutputType>WinExe</OutputType>
|
||||
<OutputType>Exe</OutputType>
|
||||
<TargetFramework>netcoreapp3.0</TargetFramework>
|
||||
<UseWindowsForms>true</UseWindowsForms>
|
||||
<StartupObject>Ryujinx.Updater.Program</StartupObject>
|
||||
<StartupObject></StartupObject>
|
||||
<AssemblyName>Updater</AssemblyName>
|
||||
<ApplicationIcon>Ryujinx.ico</ApplicationIcon>
|
||||
</PropertyGroup>
|
||||
|
|
|
@ -16,8 +16,6 @@ using System.Reflection;
|
|||
using System.Text;
|
||||
using System.Threading;
|
||||
using System.Threading.Tasks;
|
||||
using Utf8Json;
|
||||
using Utf8Json.Resolvers;
|
||||
|
||||
using GUI = Gtk.Builder.ObjectAttribute;
|
||||
|
||||
|
|
|
@ -80,12 +80,19 @@ namespace Ryujinx.Updater.Parser
|
|||
{
|
||||
try
|
||||
{
|
||||
// Create Meta.json
|
||||
|
||||
List<String> metaFileContents = new List<string>();
|
||||
metaFileContents.Add(_buildVer);
|
||||
metaFileContents.Add(_buildArt);
|
||||
File.WriteAllLines(Path.Combine(RyuDir, "Meta.json"), metaFileContents);
|
||||
|
||||
// Start Updater.exe
|
||||
|
||||
string updaterPath = Path.Combine(RyuDir, "Updater.exe");
|
||||
|
||||
Process.Start(new ProcessStartInfo(updaterPath) { UseShellExecute = true });
|
||||
Application.Quit();
|
||||
Process.Start(updaterPath);
|
||||
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
|
|
|
@ -11,8 +11,8 @@ namespace Ryujinx.Updater
|
|||
{
|
||||
public class Update
|
||||
{
|
||||
private static string _parentdir = Path.Combine(@"..\..");
|
||||
public static string RyuDir = Environment.CurrentDirectory;
|
||||
private static string _parentdir = Path.Combine(@"..\..");
|
||||
public static string RyuDir = Environment.CurrentDirectory;
|
||||
|
||||
public static void PerformUpdate()
|
||||
{
|
||||
|
|
Loading…
Add table
Reference in a new issue