diff --git a/Directory.Build.props b/Directory.Build.props
index 7f78555c7..3abe378a3 100644
--- a/Directory.Build.props
+++ b/Directory.Build.props
@@ -18,6 +18,12 @@
$(RepoPath)src\
$(RepoPath)out\
$(RepoPath)assets\
+
+
+ <_IsExeProject Condition="'$(OutputType)' == 'Exe' OR '$(OutputType)' == 'WinExe'">true
+
+
+ true
diff --git a/Directory.Build.targets b/Directory.Build.targets
new file mode 100644
index 000000000..3c84f230d
--- /dev/null
+++ b/Directory.Build.targets
@@ -0,0 +1,27 @@
+
+
+
+
+
+
+
+
+
+ $(IntermediateOutputPath)app.manifest
+
+
+
+
+
+
+
+
+
+
+
diff --git a/build/GCM.MSBuild.csproj b/build/GCM.MSBuild.csproj
new file mode 100644
index 000000000..7dbe90afe
--- /dev/null
+++ b/build/GCM.MSBuild.csproj
@@ -0,0 +1,13 @@
+
+
+
+ netstandard2.0
+ false
+
+
+
+
+
+
+
+
diff --git a/build/GCM.tasks b/build/GCM.tasks
new file mode 100644
index 000000000..fe7031f34
--- /dev/null
+++ b/build/GCM.tasks
@@ -0,0 +1,16 @@
+
+
+ <_TaskAssembly>$(MSBuildToolsPath)\Microsoft.Build.Tasks.v4.0.dll
+ <_TaskFactory>CodeTaskFactory
+
+
+ <_TaskAssembly>$(MSBuildToolsPath)\Microsoft.Build.Tasks.Core.dll
+ <_TaskFactory>RoslynCodeTaskFactory
+
+
+
+
+
+
+
+
diff --git a/build/GenerateWindowsAppManifest.cs b/build/GenerateWindowsAppManifest.cs
new file mode 100644
index 000000000..58a94c5a1
--- /dev/null
+++ b/build/GenerateWindowsAppManifest.cs
@@ -0,0 +1,51 @@
+using Microsoft.Build.Framework;
+using Microsoft.Build.Utilities;
+using System.IO;
+
+namespace GitCredentialManager.MSBuild
+{
+ public class GenerateWindowsAppManifest : Task
+ {
+ [Required]
+ public string Version { get; set; }
+
+ [Required]
+ public string ApplicationName { get; set; }
+
+ [Required]
+ public string OutputFile { get; set; }
+
+ public override bool Execute()
+ {
+ Log.LogMessage(MessageImportance.Normal, "Creating application manifest file for '{0}'...", ApplicationName);
+
+ string manifestDirectory = Path.GetDirectoryName(OutputFile);
+ if (!Directory.Exists(manifestDirectory))
+ {
+ Directory.CreateDirectory(manifestDirectory);
+ }
+
+ File.WriteAllText(
+ OutputFile,
+ $@"
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+");
+
+ return true;
+ }
+ }
+}