protected override void InternalBuild()
        {
            var x64Components = AgentComponents.GetAgentComponents(AgentType.Framework, Configuration, "x64", RepoRootDirectory, HomeRootDirectory);
            var x86Components = AgentComponents.GetAgentComponents(AgentType.Framework, Configuration, "x86", RepoRootDirectory, HomeRootDirectory);

            x64Components.ValidateComponents();
            x86Components.ValidateComponents();

            FileHelpers.CopyAll($@"{PackageDirectory}\Installer", FilesToZipFolderName);
            var replacements = new Dictionary <string, string>()
            {
                { "AGENT_VERSION_STRING", x64Components.Version }
            };

            FileHelpers.ReplaceTextInFile($@"{FilesToZipFolderName}\install.ps1", replacements);

            var agentInfo = new AgentInfo
            {
                InstallType = "ScriptableFramework"
            };

            agentInfo.WriteToDisk(FilesToZipFolderName);

            CreateNugetPackage(x64Components, x86Components, $@"{PackageDirectory}\NewRelic.Net.Agent.x64.nuspec");
            CreateNugetPackage(x86Components, x86Components, $@"{PackageDirectory}\NewRelic.Net.Agent.nuspec");

            var zipFilePath = $@"{OutputDirectory}\NewRelic.Agent.Installer.{x64Components.Version}.zip";

            Directory.CreateDirectory(OutputDirectory);
            System.IO.Compression.ZipFile.CreateFromDirectory(FilesToZipFolderName, zipFilePath);
            File.WriteAllText($@"{OutputDirectory}\checksum.sha256", FileHelpers.GetSha256Checksum(zipFilePath));
        }
        protected override void InternalBuild()
        {
            var agentComponents = AgentComponents.GetAgentComponents(AgentType, Configuration, Platform, RepoRootDirectory, HomeRootDirectory);

            agentComponents.ValidateComponents();
            agentComponents.CopyComponents(StagingDirectory);

            var agentInfo = new AgentInfo
            {
                InstallType = $"ZipWin{Platform}{AgentType.ToString()}"
            };

            agentInfo.WriteToDisk(StagingDirectory);

            var zipFilePath = AgentType == AgentType.Framework
                ? $@"{OutputDirectory}\newrelic-framework-agent_{agentComponents.Version}_{Platform}.zip"
                : $@"{OutputDirectory}\newrelic-netcore20-agent-win_{agentComponents.Version}_{Platform}.zip";

            Directory.CreateDirectory(OutputDirectory);
            System.IO.Compression.ZipFile.CreateFromDirectory(StagingDirectory, zipFilePath);
            File.WriteAllText($@"{OutputDirectory}\checksum.sha256", FileHelpers.GetSha256Checksum(zipFilePath));

            // For now, the DotNet-Core20-Agent-DeployToS3 job expects core agent artifacts to be in the following directory
            // At some point we should change the job to pull from the new location under the Build\BuildArtifacts directory
            if (AgentType == AgentType.Core)
            {
                FileHelpers.CopyFile(zipFilePath, $@"{RepoRootDirectory}\src\_build\CoreArtifacts");
            }

            Console.WriteLine($"Successfully created artifact for {nameof(ZipArchive)}.");
        }
        protected override void InternalBuild()
        {
            var rootDirectory               = $@"{StagingDirectory}\content\newrelic";
            var frameworkAgentComponents    = AgentComponents.GetAgentComponents(AgentType.Framework, Configuration, "x64", RepoRootDirectory, HomeRootDirectory);
            var frameworkAgentX86Components = AgentComponents.GetAgentComponents(AgentType.Framework, Configuration, "x86", RepoRootDirectory, HomeRootDirectory);
            var coreAgentComponents         = AgentComponents.GetAgentComponents(AgentType.Core, Configuration, "x64", RepoRootDirectory, HomeRootDirectory);
            var coreAgentX86Components      = AgentComponents.GetAgentComponents(AgentType.Core, Configuration, "x86", RepoRootDirectory, HomeRootDirectory);

            frameworkAgentComponents.ValidateComponents();
            frameworkAgentX86Components.ValidateComponents();
            coreAgentComponents.ValidateComponents();
            coreAgentX86Components.ValidateComponents();

            var package = new NugetPackage(StagingDirectory, OutputDirectory);

            frameworkAgentComponents.CopyComponents($@"{package.ContentDirectory}\newrelic");
            FileHelpers.CopyFile(frameworkAgentX86Components.WindowsProfiler, $@"{package.ContentDirectory}\newrelic\x86");
            Directory.CreateDirectory($@"{rootDirectory}\logs");
            System.IO.File.Create($@"{rootDirectory}\logs\placeholder").Dispose();

            frameworkAgentComponents.CopyComponents($@"{package.GetContentFilesDirectory("any", "net45")}\newrelic");
            FileHelpers.CopyFile(frameworkAgentX86Components.WindowsProfiler, $@"{package.GetContentFilesDirectory("any", "net45")}\newrelic\x86");
            Directory.CreateDirectory($@"{StagingDirectory}\contentFiles\any\net45\newrelic\logs");
            System.IO.File.Create($@"{StagingDirectory}\contentFiles\any\net45\newrelic\logs\placeholder").Dispose();

            coreAgentComponents.CopyComponents($@"{package.GetContentFilesDirectory("any", "netstandard2.0")}\newrelic");
            FileHelpers.CopyFile(coreAgentX86Components.WindowsProfiler, $@"{package.GetContentFilesDirectory("any", "netstandard2.0")}\newrelic\x86");
            package.CopyToContentFiles(coreAgentComponents.LinuxProfiler, @"any\netstandard2.0\newrelic");
            package.CopyToContentFiles(coreAgentComponents.GRPCExtensionsLibLinux, @"any\netstandard2.0\newrelic");
            Directory.CreateDirectory($@"{StagingDirectory}\contentFiles\any\netstandard2.0\newrelic\logs");
            System.IO.File.Create($@"{StagingDirectory}\contentFiles\any\netstandard2.0\newrelic\logs\placeholder").Dispose();

            package.CopyAll(PackageDirectory);
            var agentInfo = new AgentInfo
            {
                InstallType = "NugetAgent"
            };

            var newRelicConfigPaths = new[]
            {
                $@"{rootDirectory}\newrelic.config",
                $@"{StagingDirectory}\contentFiles\any\net45\newrelic\newrelic.config",
                $@"{StagingDirectory}\contentFiles\any\netstandard2.0\newrelic\newrelic.config",
            };

            foreach (var newRelicConfigPath in newRelicConfigPaths)
            {
                TransformNewRelicConfig(newRelicConfigPath);
                agentInfo.WriteToDisk(Path.GetDirectoryName(newRelicConfigPath));
            }

            package.SetVersion(frameworkAgentComponents.Version);

            package.Pack();
        }
        protected override void InternalBuild()
        {
            var x64Components = AgentComponents.GetAgentComponents(AgentType.Core, Configuration, "x64", RepoRootDirectory, HomeRootDirectory);
            var x86Components = AgentComponents.GetAgentComponents(AgentType.Core, Configuration, "x86", RepoRootDirectory, HomeRootDirectory);

            x64Components.ValidateComponents();
            x86Components.ValidateComponents();

            FileHelpers.DeleteDirectories(StagingDirectory, OutputDirectory);
            var agentInfox64 = new AgentInfo
            {
                InstallType = "ScriptableCore"
            };

            x64Components.CopyComponents($@"{StagingDirectory}\x64");
            x86Components.CopyComponents($@"{StagingDirectory}\x86");
            agentInfox64.WriteToDisk($@"{StagingDirectory}\x64");
            agentInfox64.WriteToDisk($@"{StagingDirectory}\x86");

            FileHelpers.CopyFile($@"{RepoRootDirectory}\build\Packaging\CoreInstaller\installAgent.ps1", StagingDirectory);
            FileHelpers.CopyFile($@"{RepoRootDirectory}\build\Packaging\CoreInstaller\installAgentUsage.txt", StagingDirectory);

            var zipFilePath = $@"{OutputDirectory}\newrelic-netcore20-agent-win-installer_{x64Components.Version}.zip";

            Directory.CreateDirectory(OutputDirectory);
            System.IO.Compression.ZipFile.CreateFromDirectory(StagingDirectory, zipFilePath);
            File.WriteAllText($@"{OutputDirectory}\checksum.sha256", FileHelpers.GetSha256Checksum(zipFilePath));

            // For now, the DotNet-Core20-Agent-DeployToS3 job expects core agent artifacts to be in the following directory
            // At some point we should change the job to pull from the new location under the Build\BuildArtifacts directory
            FileHelpers.CopyFile(zipFilePath, $@"{RepoRootDirectory}\src\_build\CoreArtifacts");

            // We put a readme file for the core agent on the download site: http://download.newrelic.com/dot_net_agent/core_20/current/
            // This readme also gets picked up by the DotNet-Core20-Agent-DeployToS3 job.
            CopyCoreReadme();
            Console.WriteLine($"Successfully created artifact for {nameof(CoreInstaller)}.");
        }
        protected override void InternalBuild()
        {
            _agentComponents = AgentComponents.GetAgentComponents(AgentType.Framework, Configuration, Platform, RepoRootDirectory, HomeRootDirectory);
            _agentComponents.ValidateComponents();

            var package = new NugetPackage(StagingDirectory, OutputDirectory);

            _agentComponents.CopyComponents($@"{package.ContentDirectory}\newrelic");
            package.CopyToLib(_agentComponents.AgentApiDll);
            package.CopyAll(PackageDirectory);
            TransformNewRelicConfig();
            var agentInfo = new AgentInfo
            {
                InstallType = $"NugetAzureWebsites{Platform}"
            };

            agentInfo.WriteToDisk(RootDirectory);
            package.SetVersion(_agentComponents.Version);
            package.Pack();
        }