Merge pull request #5767 from duplicati/release/canary-2.1.0.102
Release/canary 2.1.0.102
This commit is contained in:
@@ -40,7 +40,7 @@ public static partial class Command
|
||||
}, workingDirectory: baseDir);
|
||||
|
||||
// Then push the release
|
||||
await ProcessHelper.Execute(new[] { "git", "push" }, workingDirectory: baseDir);
|
||||
await ProcessHelper.Execute(new[] { "git", "push", "-u", "origin", "head" }, workingDirectory: baseDir);
|
||||
await ProcessHelper.Execute(new[] { "git", "push", "--tags" }, workingDirectory: baseDir);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -472,6 +472,9 @@ public static partial class Command
|
||||
throw new Exception($"The following packages cannot be built without Docker: {string.Join(", ", unsupportedBuilds.Select(x => x.PackageTargetString))}");
|
||||
}
|
||||
|
||||
// Prevent the system from going to sleep during the build
|
||||
using var _ = new KeepAliveAssertion();
|
||||
|
||||
if (rtcfg.UseGithubUpload && !input.GitStashPush)
|
||||
{
|
||||
Console.WriteLine("Github upload requested, but pushing the tag is disabled");
|
||||
|
||||
@@ -0,0 +1,78 @@
|
||||
using System.Diagnostics;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Runtime.Versioning;
|
||||
|
||||
namespace ReleaseBuilder;
|
||||
|
||||
/// <summary>
|
||||
/// A class that prevents the system from sleeping during build
|
||||
/// </summary>
|
||||
public class KeepAliveAssertion : IDisposable
|
||||
{
|
||||
/// <summary>
|
||||
/// The previous state of the system, on Windows
|
||||
/// </summary>
|
||||
private NativeMethods.EXECUTION_STATE _previousState;
|
||||
/// <summary>
|
||||
/// The process that keeps the system awake, on Linux and MacOS
|
||||
/// </summary>
|
||||
private Process? _keepAliveProcess;
|
||||
|
||||
/// <summary>
|
||||
/// Creates a new instance of the <see cref="KeepAliveAssertion"/> class
|
||||
/// </summary>
|
||||
public KeepAliveAssertion()
|
||||
{
|
||||
if (OperatingSystem.IsWindows())
|
||||
{
|
||||
_previousState = NativeMethods.SetThreadExecutionState(NativeMethods.EXECUTION_STATE.ES_CONTINUOUS | NativeMethods.EXECUTION_STATE.ES_SYSTEM_REQUIRED | NativeMethods.EXECUTION_STATE.ES_AWAYMODE_REQUIRED);
|
||||
}
|
||||
else if (OperatingSystem.IsLinux())
|
||||
{
|
||||
_keepAliveProcess = Process.Start("xset", "s off -dpms");
|
||||
}
|
||||
else if (OperatingSystem.IsMacOS())
|
||||
{
|
||||
// Keep the display awake until this process exits
|
||||
var selfProcessId = Process.GetCurrentProcess().Id;
|
||||
_keepAliveProcess = Process.Start("caffeinate", ["-d", "-w", selfProcessId.ToString()]);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// A class that contains Windows native methods
|
||||
/// </summary>
|
||||
[SupportedOSPlatform("windows")]
|
||||
private class NativeMethods
|
||||
{
|
||||
[DllImport("kernel32.dll", CharSet = CharSet.Auto, SetLastError = true)]
|
||||
public static extern EXECUTION_STATE SetThreadExecutionState(EXECUTION_STATE esFlags); // returns the previous state
|
||||
|
||||
[Flags]
|
||||
public enum EXECUTION_STATE : uint
|
||||
{
|
||||
ES_AWAYMODE_REQUIRED = 0x00000040,
|
||||
ES_CONTINUOUS = 0x80000000,
|
||||
ES_SYSTEM_REQUIRED = 0x00000001
|
||||
}
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
public void Dispose()
|
||||
{
|
||||
if (OperatingSystem.IsWindows())
|
||||
{
|
||||
NativeMethods.SetThreadExecutionState(_previousState);
|
||||
}
|
||||
else if (OperatingSystem.IsLinux())
|
||||
{
|
||||
_keepAliveProcess?.Kill();
|
||||
_keepAliveProcess?.Dispose();
|
||||
}
|
||||
else if (OperatingSystem.IsMacOS())
|
||||
{
|
||||
_keepAliveProcess?.Kill();
|
||||
_keepAliveProcess?.Dispose();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1 +1 @@
|
||||
2.1.0.101
|
||||
2.1.0.102
|
||||
@@ -1,3 +1,20 @@
|
||||
2024-12-12 - 2.1.0.102_canary_2024-12-12
|
||||
==========
|
||||
This release is a canary release intended to be used for testing.
|
||||
|
||||
**Note that this build is using .NET8, unlike the 2.0.8.1 build**
|
||||
|
||||
**Note that this build has a redesigned restore flow**
|
||||
Should issues arise, the previous restore engine can be enabled with `--restore-legacy=true`.
|
||||
|
||||
## Detailed list of changes:
|
||||
- Upgraded FluentFTP to fix a crash on socket timeout
|
||||
- Removed named channels to fix a rare exception
|
||||
- Rewrote the restore process to be multithreaded and target optimal disk I/O write performance
|
||||
- Added missing documentation to the iDrive e2 backend
|
||||
- Added activity timeout on backend transfers
|
||||
- Added support for generating a "forever token"
|
||||
|
||||
2024-12-06 - 2.1.0.101_canary_2024-12-06
|
||||
==========
|
||||
This release is a canary release intended to be used for testing.
|
||||
|
||||
Reference in New Issue
Block a user