Skip to content

Commit 9e6dfde

Browse files
committed
AutoUpdaterを搭載した
1 parent 6b40db5 commit 9e6dfde

File tree

5 files changed

+34
-40
lines changed

5 files changed

+34
-40
lines changed

ReleaseNote.xml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<item>
33
<version>1.0.4.0</version>
4-
<url>https://github.com/anoyetta/CeVIOAIProxy/releases/download/v1.0.0.0/CeVIOAIProxy.exe</url>
5-
<changelog>https://github.com/anoyetta/CeVIOAIProxy/releases/tag/v1.0.0.0</changelog>
4+
<url>https://github.com/anoyetta/CeVIOAIProxy/releases/download/v1.0.4.0/CeVIOAIProxy.exe</url>
5+
<changelog>https://github.com/anoyetta/CeVIOAIProxy/releases/tag/v1.0.4.0</changelog>
66
<mandatory>true</mandatory>
77
</item>

source/CeVIOAIProxy.sln

-32
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,6 @@ VisualStudioVersion = 16.0.31213.239
55
MinimumVisualStudioVersion = 10.0.40219.1
66
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "CeVIOAIProxy", "CeVIOAIProxy\CeVIOAIProxy.csproj", "{6E4F4DB9-1280-419E-9266-9FECE1629E60}"
77
EndProject
8-
Project("{C7167F0D-BC9F-4E6E-AFE1-012C56B48DB5}") = "CeVIOAIProxy.Package", "CeVIOAIProxy.Package\CeVIOAIProxy.Package.wapproj", "{54D67445-70D1-4AC5-BD3C-52057612A718}"
9-
EndProject
108
Global
119
GlobalSection(SolutionConfigurationPlatforms) = preSolution
1210
Debug|Any CPU = Debug|Any CPU
@@ -41,36 +39,6 @@ Global
4139
{6E4F4DB9-1280-419E-9266-9FECE1629E60}.Release|x64.Build.0 = Release|Any CPU
4240
{6E4F4DB9-1280-419E-9266-9FECE1629E60}.Release|x86.ActiveCfg = Release|Any CPU
4341
{6E4F4DB9-1280-419E-9266-9FECE1629E60}.Release|x86.Build.0 = Release|Any CPU
44-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
45-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Debug|Any CPU.Build.0 = Debug|Any CPU
46-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
47-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Debug|ARM.ActiveCfg = Debug|ARM
48-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Debug|ARM.Build.0 = Debug|ARM
49-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Debug|ARM.Deploy.0 = Debug|ARM
50-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Debug|ARM64.ActiveCfg = Debug|ARM64
51-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Debug|ARM64.Build.0 = Debug|ARM64
52-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Debug|ARM64.Deploy.0 = Debug|ARM64
53-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Debug|x64.ActiveCfg = Debug|x64
54-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Debug|x64.Build.0 = Debug|x64
55-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Debug|x64.Deploy.0 = Debug|x64
56-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Debug|x86.ActiveCfg = Debug|x86
57-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Debug|x86.Build.0 = Debug|x86
58-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Debug|x86.Deploy.0 = Debug|x86
59-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Release|Any CPU.ActiveCfg = Release|Any CPU
60-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Release|Any CPU.Build.0 = Release|Any CPU
61-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Release|Any CPU.Deploy.0 = Release|Any CPU
62-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Release|ARM.ActiveCfg = Release|ARM
63-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Release|ARM.Build.0 = Release|ARM
64-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Release|ARM.Deploy.0 = Release|ARM
65-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Release|ARM64.ActiveCfg = Release|ARM64
66-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Release|ARM64.Build.0 = Release|ARM64
67-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Release|ARM64.Deploy.0 = Release|ARM64
68-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Release|x64.ActiveCfg = Release|x64
69-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Release|x64.Build.0 = Release|x64
70-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Release|x64.Deploy.0 = Release|x64
71-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Release|x86.ActiveCfg = Release|x86
72-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Release|x86.Build.0 = Release|x86
73-
{54D67445-70D1-4AC5-BD3C-52057612A718}.Release|x86.Deploy.0 = Release|x86
7442
EndGlobalSection
7543
GlobalSection(SolutionProperties) = preSolution
7644
HideSolutionNode = FALSE

source/CeVIOAIProxy/App.xaml.cs

+25
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,13 @@
11
using System;
22
using System.IO;
3+
using System.Reflection;
34
using System.Text;
45
using System.Threading.Tasks;
56
using System.Windows;
67
using System.Windows.Interop;
78
using System.Windows.Media;
89
using System.Windows.Threading;
10+
using AutoUpdaterDotNET;
911
using CeVIOAIProxy.Servers;
1012

1113
namespace CeVIOAIProxy
@@ -36,6 +38,8 @@ private void App_Startup(object sender, StartupEventArgs e)
3638

3739
this.server = new CAPTcpServer();
3840
this.server.Open(c.TcpServerPort);
41+
42+
this.RunAutoUpdater();
3943
}
4044

4145
private void App_Exit(object sender, ExitEventArgs e)
@@ -102,5 +106,26 @@ await Task.Run(() =>
102106
GC.SuppressFinalize(this);
103107
this.Shutdown(1);
104108
}
109+
110+
private void RunAutoUpdater()
111+
{
112+
var updaterJson = Path.Combine(
113+
AppContext.BaseDirectory,
114+
"CeVIOAIProxy.AutoUpdater.json");
115+
116+
#if DEBUG
117+
if (File.Exists(updaterJson))
118+
{
119+
File.Delete(updaterJson);
120+
}
121+
#endif
122+
123+
AutoUpdater.PersistenceProvider = new JsonFilePersistenceProvider(updaterJson);
124+
125+
AutoUpdater.ShowSkipButton = false;
126+
AutoUpdater.Start(
127+
"https://raw.githubusercontent.com/anoyetta/CeVIOAIProxy/main/ReleaseNote.xml",
128+
Assembly.GetExecutingAssembly());
129+
}
105130
}
106131
}

source/CeVIOAIProxy/CeVIOAIProxy.csproj

+4-3
Original file line numberDiff line numberDiff line change
@@ -11,13 +11,14 @@
1111
<AssemblyOriginatorKeyFile>CeVIOAIProxy.pfx</AssemblyOriginatorKeyFile>
1212
<Authors>anoyetta</Authors>
1313
<Copyright>(c) 2021 anoyetta</Copyright>
14-
<AssemblyVersion>1.0.3.0</AssemblyVersion>
14+
<AssemblyVersion>1.0.4.0</AssemblyVersion>
1515
<PackageIcon>share.ico</PackageIcon>
1616
<PackageIconUrl />
1717
<PackageProjectUrl>https://github.com/anoyetta/CeVIOAIProxy</PackageProjectUrl>
1818
<RepositoryUrl>https://github.com/anoyetta/CeVIOAIProxy.git</RepositoryUrl>
1919
<RepositoryType>GitHub</RepositoryType>
20-
<Version>1.0.3</Version>
20+
<Version>1.0.4</Version>
21+
<StartupObject>CeVIOAIProxy.App</StartupObject>
2122
</PropertyGroup>
2223

2324
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
@@ -40,6 +41,7 @@
4041
</ItemGroup>
4142

4243
<ItemGroup>
44+
<PackageReference Include="Autoupdater.NET.Official" Version="1.6.4" />
4345
<PackageReference Include="Costura.Fody" Version="5.3.0">
4446
<PrivateAssets>all</PrivateAssets>
4547
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
@@ -50,7 +52,6 @@
5052
<PackageReference Include="MahApps.Metro.IconPacks" Version="4.8.0" />
5153
<PackageReference Include="MaterialDesignThemes.MahApps" Version="0.1.6" />
5254
<PackageReference Include="Microsoft.Xaml.Behaviors.Wpf" Version="1.1.31" />
53-
<PackageReference Include="Nancy" Version="2.0.0" />
5455
<PackageReference Include="Nancy.Hosting.Self" Version="2.0.0" />
5556
<PackageReference Include="NETStandard.Library" Version="2.0.3" />
5657
<PackageReference Include="Newtonsoft.Json" Version="13.0.1" />

source/CeVIOAIProxy/FodyWeavers.xml

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<Weavers
2-
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
3-
xsi:noNamespaceSchemaLocation="FodyWeavers.xsd">
1+
<Weavers xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="FodyWeavers.xsd">
2+
<Costura
3+
IncludeDebugSymbols="false" />
44
</Weavers>

0 commit comments

Comments
 (0)