public GlobOption(Option <IEnumerable <string> > option, GlobKind kind, string source, string target, string optionalFilesPath) : base(option.Source, option.Name, option.Value) { Kind = kind; this.source = source; this.target = target; this.optionalFilesPath = optionalFilesPath; }
public static GlobOption GetGlob(this IEnumerable <Args> args, GlobKind kind, string source, string target, string optionalFilesPath, [CallerMemberName] string name = null) => new GlobOption(args.Get <IEnumerable <string> >(null, name), kind, source, target, optionalFilesPath);
private static bool Add(this Manifest application, Project project, string source, string target, GlobKind kind, string group = null) { if (source is null || target is null) { return(false); } if (kind == GlobKind.Assemblies && application.AssemblyReferences.FindTargetPath(target) is null && application.FileReferences.FindTargetPath(target) is null) { var identity = AssemblyIdentity.FromManagedAssembly(source); if (identity is null) { Logger.Verbose(Messages.Build_Process_Glob_Skipped, 1, 1, source); return(false); } application.AssemblyReferences.Add(new AssemblyReference { SourcePath = source, TargetPath = target, AssemblyIdentity = AssemblyIdentity.FromFile(source), IsOptional = group != null, Group = group }); }