Skip to content

Commit

Permalink
Single file publish configured
Browse files Browse the repository at this point in the history
  • Loading branch information
julr committed Feb 9, 2022
1 parent d7df740 commit c1b08ee
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
3 changes: 2 additions & 1 deletion OBS App/MainWindow.xaml.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
using Bluegrams.Application;
using System;
using System.Diagnostics;
using System.IO;
using System.Timers;
using System.Windows;
Expand All @@ -20,7 +21,7 @@ public MainWindow()
#pragma warning restore CS8618 // Non-nullable field must contain a non-null value when exiting constructor. Consider declaring as nullable.
{
PortableSettingsProvider.SettingsFileName = System.Reflection.Assembly.GetExecutingAssembly().GetName().Name + ".config";
PortableSettingsProvider.SettingsDirectory = Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().Location);
PortableSettingsProvider.SettingsDirectory = Path.GetDirectoryName(Process.GetCurrentProcess().MainModule!.FileName);
PortableSettingsProvider.ApplyProvider(Properties.Settings.Default);

InitializeComponent();
Expand Down
3 changes: 3 additions & 0 deletions OBS App/Properties/PublishProfiles/FolderProfile.pubxml
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,8 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
<PublishProtocol>FileSystem</PublishProtocol>
<TargetFramework>net5.0-windows</TargetFramework>
<SelfContained>false</SelfContained>
<RuntimeIdentifier>win-x64</RuntimeIdentifier>
<PublishSingleFile>True</PublishSingleFile>
<PublishReadyToRun>True</PublishReadyToRun>
</PropertyGroup>
</Project>

0 comments on commit c1b08ee

Please sign in to comment.