Compare commits
2 commits
Author | SHA1 | Date | |
---|---|---|---|
78492f83ec | |||
98c82b17ed |
3 changed files with 12 additions and 4 deletions
EllieHub
|
@ -20,7 +20,7 @@
|
|||
<DebugType>embedded</DebugType>
|
||||
|
||||
<!--Version-->
|
||||
<VersionPrefix>1.0.5.0</VersionPrefix>
|
||||
<VersionPrefix>1.0.7.0</VersionPrefix>
|
||||
|
||||
<!--Avalonia Settings-->
|
||||
<ApplicationManifest>app.manifest</ApplicationManifest>
|
||||
|
@ -58,7 +58,7 @@
|
|||
<PackageReference Include="Microsoft.Extensions.Caching.Memory" Version="9.0.0" />
|
||||
<PackageReference Include="Microsoft.Extensions.DependencyInjection" Version="9.0.0" />
|
||||
<!--Condition below is needed to remove Avalonia.Diagnostics package from build output in Release configuration.-->
|
||||
<PackageReference Condition="'$(Configuration)' == 'Debug'" Include="Avalonia.Diagnostics" Version="11.0.10" />
|
||||
<PackageReference Condition="'$(Configuration)' == 'Debug'" Include="Avalonia.Diagnostics" Version="11.1.5" />
|
||||
<PackageReference Include="Microsoft.Extensions.Http" Version="9.0.0" />
|
||||
<PackageReference Include="SingleFileExtractor.Core" Version="2.2.0" />
|
||||
<PackageReference Include="SkiaImageView.Avalonia11" Version="1.5.0" />
|
||||
|
|
|
@ -85,7 +85,7 @@ public sealed class YtdlpResolver : IYtdlpResolver
|
|||
/// <inheritdoc />
|
||||
public async ValueTask<string> GetLatestVersionAsync(CancellationToken cToken = default)
|
||||
{
|
||||
var http = _httpClientFactory.CreateClient(AppConstants.ToastielabClient);
|
||||
var http = _httpClientFactory.CreateClient(AppConstants.NoRedirectClient);
|
||||
|
||||
var response = await http.GetAsync("https://github.com/yt-dlp/yt-dlp/releases/latest", cToken);
|
||||
|
||||
|
|
|
@ -143,7 +143,15 @@ public sealed class AppResolver : IAppResolver
|
|||
|
||||
// Rename the original file from "file" to "file_old".
|
||||
if (File.Exists(destinationUri))
|
||||
File.Move(destinationUri, destinationUri + OldFileSuffix, true); // This executes fine
|
||||
{
|
||||
if (Environment.OSVersion.Platform is not PlatformID.Unix)
|
||||
File.Move(destinationUri, destinationUri + OldFileSuffix, true);
|
||||
else
|
||||
{
|
||||
using var moveProcess = ToastieUtilities.StartProcess("mv", [destinationUri, destinationUri + OldFileSuffix]);
|
||||
await moveProcess.WaitForExitAsync(cToken);
|
||||
}
|
||||
}
|
||||
|
||||
// Move the new file to the application's directory.
|
||||
// ...
|
||||
|
|
Loading…
Add table
Reference in a new issue