/
Legacy .NET agent - Scanning the build binaries

Legacy .NET agent - Scanning the build binaries

The SeaLights .NET agent can scan the binaries after the build process to gather the build structure.

Generating a session ID

Before running the build scan and tests, you need to create a session ID. The session ID is provided for each step in order to link them together as one complete cycle

SL.DotNet.exe config --appName "myApp" --branchName "master" --buildName $(Get-Date -Format "yyyyMMdd_HHmm") --includeNamespace myNameSpace.* --buildSessionIdFile buildSessionId.txt

As a buildName you can use also the Version generated on the application’s executables (DLL or EXE) via the following command (Get-Command "c:\path\to\binaries").FileVersionInfo.FileVersionRaw.ToString()

Scanning the binaries

Run the scan of your binaries using the SeaLights agent with the following command:

SL.DotNet.exe scan --buildSessionIdFile buildSessionId.txt --workspacePath c:\path\to\binaries --ignoreGeneratedCode true

The workspacePath folder must contain all the project’s PDB files.

As SeaLights is using the compilation method's bytecode signature (Hash ID) to generate a unique identifier for each method, it is important NOT to recompile the application between the scan command and the deployment. The scanned build's artefact (DLL, EXE) MUST be from the exact same compilation as the one deployed.



Related content

Legacy .NET agent - command reference
Legacy .NET agent - command reference
Read with this
SeaLights .NET Core agent - Scanning the build binaries
SeaLights .NET Core agent - Scanning the build binaries
More like this
Legacy .NET agent - Setting up a windows service
Legacy .NET agent - Setting up a windows service
Read with this
Legacy .NET agent - Scanning a build using MSBuild
Legacy .NET agent - Scanning a build using MSBuild
More like this
Legacy .NET agent - Capturing coverage from a windows process
Legacy .NET agent - Capturing coverage from a windows process
Read with this
SeaLights ADO Extension - Setting up the Build scan and Unit Tests
SeaLights ADO Extension - Setting up the Build scan and Unit Tests
More like this