Skip to content

Commit

Permalink
Fix path issue with auto updater
Browse files Browse the repository at this point in the history
  • Loading branch information
rik-smeets committed Apr 27, 2021
1 parent 693e63c commit 7b26694
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
10 changes: 9 additions & 1 deletion Harmonia/Bootstrapper.cs
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
using Harmonia.Services;
using System.Diagnostics;
using System.Reflection;
using Harmonia.Services;
using Harmonia.Services.Interfaces;
using Harmonia.Settings;
using Harmonia.Settings.Interfaces;
using Harmonia.Wrappers;
using Harmonia.Wrappers.Interfaces;
using MahApps.Metro.Controls.Dialogs;
using Onova;
using Onova.Models;
using Onova.Services;
using Unity;

Expand Down Expand Up @@ -55,7 +58,12 @@ private static void RegisterExternalDependencies(IUnityContainer container)

private static UpdateManager CreateUpdateManager()
{
var entryAssembly = Assembly.GetEntryAssembly();
var executablePath = Process.GetCurrentProcess().MainModule.FileName;
var assemblyMetaData = AssemblyMetadata.FromAssembly(entryAssembly, executablePath);

return new UpdateManager(
assemblyMetaData,
new GithubPackageResolver("rik-smeets", "Harmonia", "*.zip"),
new ZipPackageExtractor());
}
Expand Down
2 changes: 1 addition & 1 deletion Harmonia/Harmonia.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
<ApplicationIcon>.\Assets\harmonia.ico</ApplicationIcon>
<AssemblyName>Harmonia</AssemblyName>
<RootNamespace>Harmonia</RootNamespace>
<Version>2.0.1</Version>
<Version>2.1.0</Version>
</PropertyGroup>

<ItemGroup>
Expand Down

0 comments on commit 7b26694

Please sign in to comment.