using System; using System.Collections.Generic; using System.Linq; using System.Text.Json.Serialization; using Wabbajack.DTOs; using Wabbajack.Paths; namespace Wabbajack.Compiler; public class CompilerSettings { public bool ModlistIsNSFW { get; set; } public AbsolutePath Source { get; set; } public AbsolutePath Downloads { get; set; } public Game Game { get; set; } public AbsolutePath OutputFile { get; set; } public AbsolutePath ModListImage { get; set; } public bool UseGamePaths { get; set; } public bool UseTextureRecompression { get; set; } = false; public Game[] OtherGames { get; set; } = Array.Empty(); public TimeSpan MaxVerificationTime { get; set; } = TimeSpan.FromMinutes(1); public string ModListName { get; set; } = ""; public string ModListAuthor { get; set; } = ""; public string ModListDescription { get; set; } = ""; public string ModListReadme { get; set; } = ""; public Uri? ModListWebsite { get; set; } public Version ModlistVersion { get; set; } = Version.Parse("0.0.1.0"); public bool PublishUpdate { get; set; } = false; public string MachineUrl { get; set; } = ""; /// /// The main (default) profile /// public string Profile { get; set; } = ""; /// /// Secondary profiles to include in the modlist /// public string[] AdditionalProfiles { get; set; } = Array.Empty(); /// /// All profiles to be added to the compiled modlist /// [JsonIgnore] public IEnumerable AllProfiles => AdditionalProfiles.Append(Profile); [JsonIgnore] public bool IsMO2Modlist => AllProfiles.Any(p => !string.IsNullOrWhiteSpace(p)); /// /// This file, or files in these folders, are automatically included if they don't match /// any other step /// public RelativePath[] NoMatchInclude { get; set; } = Array.Empty(); /// /// These files are inlined into the modlist /// public RelativePath[] Include { get; set; } = Array.Empty(); /// /// These files are ignored when compiling the modlist /// public RelativePath[] Ignore { get; set; } = Array.Empty(); public RelativePath[] AlwaysEnabled { get; set; } = Array.Empty(); public Version Version { get; set; } public string Description { get; set; } }