/// <summary>
 ///     Write all the output files to the output directory defined in the options after performing a function.
 /// </summary>
 ///
 /// <example>
 ///     The following will output a single file (`NewName.md`) to `OutputDirectory`:
 ///
 ///     ```c#
 ///         new MetalsharpProject()
 ///         .AddOutput("text", "File.md")
 ///         .Build(i => i.OutputFiles.First(file => file.Name == "File").Name = "NewName", new BuildOptions { OutputDirectory = "OutputDirectory" });
 ///     ```
 /// </example>
 ///
 /// <param name="func">
 ///     The function to perform before the files are output.
 /// </param>
 /// <param name="options">
 ///     The options to configure the building behavior.
 /// </param>
 public void Build(Action <MetalsharpProject> func, BuildOptions options)
 {
     BeforeBuild?.Invoke(this, new EventArgs());
     func(this);
     AfterBuild?.Invoke(this, new EventArgs());
     Build(options);
 }
 private void OnAfterBuild(BuildResult result)
 => AfterBuild?.Invoke(this, new BuildResultEventArgs(result));