2023.12.6.1

Update updater
YT: add new version check at start
This commit is contained in:
Andy
2023-12-06 18:28:36 +03:00
parent c92314d8e8
commit 0657f3d195
22 changed files with 591 additions and 61 deletions

View File

@@ -12,8 +12,8 @@ Imports PersonalUtilities.Functions
Imports PersonalUtilities.Functions.XML
Imports PersonalUtilities.Tools.Web.Clients
Imports PersonalUtilities.Tools.Web.Documents.JSON
Imports SCrawler.Shared
Public Module MainMod
Private Const NewReleaseFolderName As String = "__NewRelease"
Private MyProcessID As Integer = -1
Private MyWorkingPath As SFile = Nothing
Private ReadOnly ProcessNames As String() = {"SCrawler", "YouTubeDownloader", "Updater"}
@@ -226,23 +226,4 @@ Public Module MainMod
End Try
Return Nothing
End Function
Private Function GetCurrentMaxVer(ByVal Path As SFile) As Version
Try
If Path.Exists(SFO.Path, False) Then
Dim versions As New List(Of Version)
Dim v As FileVersionInfo
With SFile.GetFiles(Path, "*.exe",, EDP.ReturnValue).ListIfNothing.Where(Function(f) f.Name = "SCrawler" Or f.Name = "YouTubeDownloader")
If .ListExists Then
For Each f As SFile In .Self
v = FileVersionInfo.GetVersionInfo(f)
versions.Add(New Version(v.ProductVersion))
Next
End If
End With
If versions.Count > 0 Then Return versions.LastOrDefault
End If
Catch
End Try
Return Nothing
End Function
End Module