Free, open-source file converter. Convert 263 formats offline by drag & drop — images, PDF, Word, Excel, PowerPoint, HWP/HWPX, video, audio, e-books and archives. No upload, no Office needed.
C# audio-converteravaloniabatch-conversionconvertercsharpdocument-converterdocx-to-pdfdotnetdrag-and-dropfile-conversionfile-converterheic-converterhwphwpximage-converterlinuxmacospdf-convertervideo-converterwindows
FreeMASTER CSV: keep the route, not a slot on every text donut
KnifeLemon7ec08ae039a0
diff --git a/src/Filee.Core/Presets/BuiltInData.cs b/src/Filee.Core/Presets/BuiltInData.csindex ff5ae591..ffab9bc7 100644--- a/src/Filee.Core/Presets/BuiltInData.cs+++ b/src/Filee.Core/Presets/BuiltInData.cs@@ -651,7 +651,7 @@ public static class BuiltInDataNameKey = "profile.text",Extensions = ExtensionsOf(FormatCategory.Text),PresetIds = ["to-pdf", "to-hwpx", "to-hwp", "to-docx", "to-html", "to-txt", "to-epub"],- BackPresetIds = ["to-md", "to-odt", "to-rtf", "to-kepub", "to-csv", "merge-pdf", "zip-all"],+ BackPresetIds = ["to-md", "to-odt", "to-rtf", "to-kepub", "merge-pdf", "zip-all"],};/// <summary>Donuts of the categories added in settings schema 6, in the order they follow "text".</summary>diff --git a/src/Filee.Core/Settings/AppSettings.cs b/src/Filee.Core/Settings/AppSettings.csindex 08f12f75..f32156ea 100644--- a/src/Filee.Core/Settings/AppSettings.cs+++ b/src/Filee.Core/Settings/AppSettings.cs@@ -123,7 +123,7 @@ public sealed class DonutSettingspublic sealed class AppSettings{/// <summary>Current schema version. Increase when the format changes and add a migration.</summary>- public const int CurrentSchemaVersion = 55;+ public const int CurrentSchemaVersion = 54;public int SchemaVersion { get; set; } = CurrentSchemaVersion;diff --git a/src/Filee.Core/Settings/UserDataStore.cs b/src/Filee.Core/Settings/UserDataStore.csindex 350d72e1..b788b690 100644--- a/src/Filee.Core/Settings/UserDataStore.cs+++ b/src/Filee.Core/Settings/UserDataStore.cs@@ -931,14 +931,6 @@ internal static class SettingsMigrations// donut; custom claims stay put.if (from < 54)changed |= LearnExtensions(profiles, out _, ["001", "7z.001", "zip.001", "tar.001"]);- // v55: offer CSV on the text donut for FreeMASTER oscilloscope exports when a slot is free (#571).- if (from < 55 && presets.Any(p => p.Id == "to-csv")- && profiles.FirstOrDefault(p => p.Id == "text") is { BackPresetIds: { } textBack } textProfile- && !textProfile.PresetIds.Contains("to-csv") && !textBack.Contains("to-csv") && textBack.Count < ToolbarProfile.MaxSlices)- {- InsertBefore(textBack, "to-csv", "merge-pdf");- changed = true;- }return changed;}diff --git a/tests/Filee.Core.Tests/FreeMasterProfileTests.cs b/tests/Filee.Core.Tests/FreeMasterProfileTests.csdeleted file mode 100644index 39e43073..00000000--- a/tests/Filee.Core.Tests/FreeMasterProfileTests.cs+++ /dev/null@@ -1,40 +0,0 @@-// Existing text donuts can offer FreeMASTER TXT → CSV without changing custom layouts.--using Filee.Core.Presets;-using Filee.Core.Profiles;-using Filee.Core.Settings;--namespace Filee.Core.Tests;--public class FreeMasterProfileTests-{- [Fact]- public void New_text_profile_offers_csv()- {- Assert.Contains("to-csv", BuiltInData.TextProfile().BackPresetIds!);- }-- [Fact]- public void Migration_offers_csv_only_once_and_respects_existing_choices()- {- var presets = BuiltInData.CreatePresets();- var profiles = BuiltInData.CreateProfiles();- var text = profiles.Single(p => p.Id == "text");- text.BackPresetIds!.Remove("to-csv");- Assert.True(SettingsMigrations.ApplyToLibrary(54, presets, profiles));- Assert.Contains("to-csv", text.BackPresetIds);- Assert.False(SettingsMigrations.ApplyToLibrary(54, presets, profiles));-- text.BackPresetIds.Remove("to-csv");- text.PresetIds.Add("to-csv");- Assert.False(SettingsMigrations.ApplyToLibrary(54, presets, profiles));- Assert.DoesNotContain("to-csv", text.BackPresetIds);-- text.PresetIds.Remove("to-csv");- while (text.BackPresetIds.Count < ToolbarProfile.MaxSlices)- text.BackPresetIds.Add("user-" + text.BackPresetIds.Count);- Assert.False(SettingsMigrations.ApplyToLibrary(54, presets, profiles));- Assert.DoesNotContain("to-csv", text.BackPresetIds);- Assert.False(SettingsMigrations.ApplyToLibrary(55, presets, profiles));- }-}