diff --git a/RyuUpdater/Program.cs b/RyuUpdater/Program.cs
index d0efb1d..17dd86c 100644
--- a/RyuUpdater/Program.cs
+++ b/RyuUpdater/Program.cs
@@ -1,5 +1,6 @@
using System.Diagnostics;
using System.IO.Compression;
+using Utils;
namespace RyuUpdater;
@@ -31,6 +32,8 @@ private static async Task Main(string[] args) {
ZipFile.ExtractToDirectory(updateFile, targetDir, overwriteFiles: true);
Directory.Delete(tempDir, recursive: true);
+
+ Flags.CreateFlag(Constants.UPDATE_RECENT_FLAG_FILE_NAME);
var srmmPath = Path.Combine(targetDir, srmmFileName);
diff --git a/RyuUpdater/RyuUpdater.csproj b/RyuUpdater/RyuUpdater.csproj
index 41e9bdd..29418c4 100644
--- a/RyuUpdater/RyuUpdater.csproj
+++ b/RyuUpdater/RyuUpdater.csproj
@@ -12,10 +12,14 @@
..\ShinRyuModManager-CE\UserInterface\Assets\Icons\SRMM_icon.ico
true
false
- 1.0.0
+ 1.0.1
$(AssemblyVersion)
$(AssemblyVersion)
false
+
+
+
+
diff --git a/ShinRyuModManager-CE/Settings.cs b/ShinRyuModManager-CE/Settings.cs
index 3423d67..710b6a2 100644
--- a/ShinRyuModManager-CE/Settings.cs
+++ b/ShinRyuModManager-CE/Settings.cs
@@ -3,14 +3,6 @@ namespace ShinRyuModManager;
public static class Settings {
//TEMP
public const string TEMP_DIRECTORY_NAME = "ShinRyuModManager";
-
- //UPDATES
- public const string UPDATER_EXECUTABLE_NAME = "RyuUpdater.exe";
- public const string UPDATE_FLAG_FILE_NAME = "update.txt";
- public const string UPDATE_RECENT_FLAG_FILE_NAME = ".SRMM_RECENT_UPDATE_FLAG";
- public const string UPDATE_INFO_REPO_OWNER = "SRMM-Studio";
- public const string UPDATE_INFO_REPO = "srmm-version-info";
- public const string UPDATE_INFO_FILE_PATH = "RyuUpdater/config.yaml";
//EVENTS
public const string EVENT_FOOLS24_FLAG_FILE_NAME = ".SRMM_FOOLS24_FLAG";
diff --git a/ShinRyuModManager-CE/ShinRyuModManager-CE.csproj b/ShinRyuModManager-CE/ShinRyuModManager-CE.csproj
index 2507706..2ed5276 100644
--- a/ShinRyuModManager-CE/ShinRyuModManager-CE.csproj
+++ b/ShinRyuModManager-CE/ShinRyuModManager-CE.csproj
@@ -14,7 +14,7 @@
true
- 1.2.1
+ 1.2.2
$(AssemblyVersion)
ShinRyuModManager-CE
SRMM Studio
diff --git a/ShinRyuModManager-CE/UserInterface/Assets/changelog.md b/ShinRyuModManager-CE/UserInterface/Assets/changelog.md
index 2939a89..21a4b1c 100644
--- a/ShinRyuModManager-CE/UserInterface/Assets/changelog.md
+++ b/ShinRyuModManager-CE/UserInterface/Assets/changelog.md
@@ -1,3 +1,8 @@
+> ### **%{color:orange} Version 1.2.2 %** ###
+* Fixed bug with the recent update flag
+
+---
+
> ### **%{color:orange} Version 1.2.1 %** ###
* Fixed linux bug with auto updater failing to check version
diff --git a/ShinRyuModManager-CE/UserInterface/Views/MainWindow.axaml.cs b/ShinRyuModManager-CE/UserInterface/Views/MainWindow.axaml.cs
index 183adef..40d9239 100644
--- a/ShinRyuModManager-CE/UserInterface/Views/MainWindow.axaml.cs
+++ b/ShinRyuModManager-CE/UserInterface/Views/MainWindow.axaml.cs
@@ -30,10 +30,10 @@ public MainWindow() {
private void Window_OnLoaded(object sender, RoutedEventArgs e) {
// Display change log if the recent update flag exists
- if (Utils.CheckFlag(Settings.UPDATE_RECENT_FLAG_FILE_NAME)) {
+ if (Flags.CheckFlag(Constants.UPDATE_RECENT_FLAG_FILE_NAME)) {
CreateOrActivateWindow();
- Utils.DeleteFlag(Settings.UPDATE_RECENT_FLAG_FILE_NAME);
+ Flags.DeleteFlag(Constants.UPDATE_RECENT_FLAG_FILE_NAME);
}
RunPreInitAsync().ConfigureAwait(false);
diff --git a/ShinRyuModManager-CE/Utils.cs b/ShinRyuModManager-CE/Utils.cs
index 5d43a87..4282f06 100644
--- a/ShinRyuModManager-CE/Utils.cs
+++ b/ShinRyuModManager-CE/Utils.cs
@@ -18,34 +18,6 @@ public static string NormalizeNameLower(string path) {
public static string NormalizeToNodePath(string path) {
return NormalizeSeparator(path, NodeSystem.PathSeparator.ToCharArray()[0]);
}
-
- internal static bool CheckFlag(string flagName) {
- var currentPath = Path.GetDirectoryName(Environment.CurrentDirectory);
- var flagFilePath = Path.Combine(currentPath, flagName);
-
- return File.Exists(flagFilePath);
- }
-
- internal static void CreateFlag(string flagName) {
- if (CheckFlag(flagName))
- return;
-
- var currentPath = Path.GetDirectoryName(Environment.CurrentDirectory);
- var flagFilePath = Path.Combine(currentPath, flagName);
-
- File.Create(flagFilePath);
- File.SetAttributes(flagFilePath, File.GetAttributes(flagFilePath) | FileAttributes.Hidden);
- }
-
- internal static void DeleteFlag(string flagName) {
- if (!CheckFlag(flagName))
- return;
-
- var currentPath = Path.GetDirectoryName(Environment.CurrentDirectory);
- var flagFilePath = Path.Combine(currentPath, flagName);
-
- File.Delete(flagFilePath);
- }
internal static bool IsFileLocked(string path) {
if (!File.Exists(path))
diff --git a/Utils/Constants.cs b/Utils/Constants.cs
index 9c76107..9e74320 100644
--- a/Utils/Constants.cs
+++ b/Utils/Constants.cs
@@ -1,6 +1,7 @@
namespace Utils;
public static class Constants {
+ // File Names
public const string INI = "YakuzaParless.ini";
public const string TXT = "ModList.txt";
public const string TXT_OLD = "ModLoadOrder.txt";
@@ -28,4 +29,12 @@ public static class Constants {
"particle",
"stage"
];
+
+ // Updates
+ public const string UPDATER_EXECUTABLE_NAME = "RyuUpdater.exe";
+ public const string UPDATE_FLAG_FILE_NAME = "update.txt";
+ public const string UPDATE_RECENT_FLAG_FILE_NAME = ".SRMM_RECENT_UPDATE_FLAG";
+ public const string UPDATE_INFO_REPO_OWNER = "SRMM-Studio";
+ public const string UPDATE_INFO_REPO = "srmm-version-info";
+ public const string UPDATE_INFO_FILE_PATH = "RyuUpdater/config.yaml";
}
diff --git a/Utils/Flags.cs b/Utils/Flags.cs
new file mode 100644
index 0000000..af7418e
--- /dev/null
+++ b/Utils/Flags.cs
@@ -0,0 +1,28 @@
+namespace Utils;
+
+public static class Flags {
+ public static bool CheckFlag(string flagName) {
+ var flagFilePath = Path.Combine(Environment.CurrentDirectory, flagName);
+
+ return File.Exists(flagFilePath);
+ }
+
+ public static void CreateFlag(string flagName) {
+ if (CheckFlag(flagName))
+ return;
+
+ var flagFilePath = Path.Combine(Environment.CurrentDirectory, flagName);
+
+ File.Create(flagFilePath);
+ File.SetAttributes(flagFilePath, File.GetAttributes(flagFilePath) | FileAttributes.Hidden);
+ }
+
+ public static void DeleteFlag(string flagName) {
+ if (!CheckFlag(flagName))
+ return;
+
+ var flagFilePath = Path.Combine(Environment.CurrentDirectory, flagName);
+
+ File.Delete(flagFilePath);
+ }
+}