Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/c#/GeneralUpdate.Core/Configuration/Option.cs
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ public override bool Equals(object? obj)

public static Option<bool?> PatchEnabled { get; } = ValueOf<bool?>("PATCH", true);

public static Option<bool?> BackupEnabled { get; } = ValueOf<bool?>("BACKUP", true);
public static Option<bool?> BackupEnabled { get; } = ValueOf<bool?>("BACKUP", false);

public static Option<bool> Silent { get; } = ValueOf<bool>("ENABLESILENTUPDATE", false);

Expand Down
2 changes: 1 addition & 1 deletion src/c#/GeneralUpdate.Core/Configuration/UpdateContext.cs
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ public class UpdateContext : UpdateConfiguration

/// <summary>
/// Whether to back up the current version before applying an update.
/// Computed from <see cref="Option.BackupEnabled" />, defaults to <c>true</c>.
/// Computed from <see cref="Option.BackupEnabled" />, defaults to <c>false</c>.
/// </summary>
public bool? BackupEnabled { get; set; }

Expand Down
4 changes: 2 additions & 2 deletions src/c#/GeneralUpdate.Core/FileSystem/StorageManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -727,9 +727,9 @@ public sealed class BackupConfig
public List<string> Directories { get; set; } = new();

/// <summary>
/// Whether the backup feature is enabled. Default is <c>true</c>.
/// Whether the backup feature is enabled. Default is <c>false</c>.
/// </summary>
public bool Enabled { get; set; } = true;
public bool Enabled { get; set; } = false;
}

/// <summary>
Expand Down
4 changes: 2 additions & 2 deletions tests/CoreTest/Configuration/UpdateContextWiringTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -205,8 +205,8 @@ public void Options_VerifyChecksum_DefaultIsTrue()
=> Assert.True(Option.VerifyChecksum.DefaultValue);

[Fact]
public void Options_BackupEnabled_DefaultIsTrue()
=> Assert.True(Option.BackupEnabled.DefaultValue);
public void Options_BackupEnabled_DefaultIsFalse()
=> Assert.False(Option.BackupEnabled.DefaultValue);

[Fact]
public void Options_PatchEnabled_DefaultIsTrue()
Expand Down
2 changes: 1 addition & 1 deletion tests/CoreTest/Configuration/UpdateOptionsStaticTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ public void PatchEnabled_HasCorrectDefault()
[Fact]
public void BackupEnabled_HasCorrectDefault()
{
Assert.True(Option.BackupEnabled.DefaultValue);
Assert.False(Option.BackupEnabled.DefaultValue);
}

[Fact]
Expand Down
Loading