namespace Common; public class ExecProcess { /// /// 步骤 /// public SyncProcessStep Step { get; set; } /// /// A after B before /// public required string StepBeforeOrAfter { get; set; } /// /// L Local S Server /// public required string ExecInLocalOrServer { get; set; } /// /// 执行的应用程序名称 /// public required string FileName { get; set; } /// /// 执行的应用程序参数 /// public required string Argumnets { get; set; } } public class DirFileConfig { /// /// 相对路径,与根路径拼成一个完整的路径,注意 "/" 不要缺少 /// public required string DirPath { get; set; } /// /// 排除的文件,它是根目录的相对路径 /// public List? Excludes { get; set; } /// /// 除此外全部忽略,最高优先级,若有值,ExcludeFiles 将被忽略,它是根目录的相对路径 /// public List? CherryPicks { get; set; } /// /// 本地文件信息,也是即将发布的文件信息,通常是最新的版本 /// public Dir? LocalDirInfo { get; set; } /// /// 差异文件信息 /// public Dir? DiffDirInfo { get; set; } /// /// 远程文件信息,通常是较旧的版本 /// public Dir? RemoteDirInfo { get; set; } } public class MSSqlConfig { /// /// 数据库地址 /// public required string ServerName { get; set; } /// /// db名称 /// public required string DatabaseName { get; set; } /// /// 用户 /// public required string User { get; set; } /// /// 密码 /// public required string Password { get; set; } /// /// 通常是:True /// public required string TrustServerCertificate { get; set; } /// /// 同步数据的表格 !!! 通常是 dbo.TableName !!! 注意dbo. /// public List? SyncTablesData { get; set; } } public class Config { /// /// 发布的项目名称 /// public required string Name { get; set; } /// /// 本次发布的唯一id /// public Guid Id { get; set; } = Guid.NewGuid(); /// /// 远程Url /// public required string RemoteUrl { get; set; } /// /// 链接到远程的密码 /// public required string RemotePwd { get; set; } /// /// 是否发布数据库 /// public required bool IsDeployDb { get; set; } /// /// 源数据库连接(ip地址相对LocalServer) /// public required MSSqlConfig SrcDb { get; set; } /// /// 目标数据库(ip地址相对RemoteServer) /// public required MSSqlConfig DstDb { get; set; } /// /// 是否发布项目 /// public required bool IsDeployProject { get; set; } /// /// 项目的绝对路径 空字符串表示不发布,不为空LocalRootPath将是发布路径。 /// public required string LocalProjectAbsolutePath { get; set; } /// /// 本地父文件路径 /// public required string LocalRootPath { get; set; } /// /// 远程父路径 /// public required string RemoteRootPath { get; set; } /// /// 同步的文件夹配置 /// public required List DirFileConfigs { get; set; } /// /// 按照步骤执行应用程序扩展列表 /// public required List ExecProcesses { get; set; } }