Compiling From Source

Installing Prerequisites

Only the .NET 6 SDK is required to compile the project. This can be installed through one of the following methods

Using Chocolatey

choco install dotnet-6.0-sdk
# Needs to be removed, in order to resolve issue with Nuget being preconfigured wrong.  
# Will auto-regenerate on first run.
Remove-Item "C:\Users\$Env:USERNAME\AppData\Roaming\NuGet\nuget.config"

Manually

The latest .NET 6.0 SDK can be found here .NET 6.0 SDK - Windows x64 Installer

Cloning the repo and submodules

git clone --recurse-submodules -j8 https://github.com/tpill90/epic-lancache-prefill.git

If you've already cloned the repository without the submodules, use this command to include the submodules:

git submodule update --init --recursive

Compiling

The project can be compiled by running the following in the repository root (the directory with the .sln file). This will generate an .exe that can be run locally. Subsequent dotnet build commands will perform incremental compilation.

dotnet build

Running the project

Note

These steps assume that the working directory is /EpicPrefill. All commands assume that they can find EpicPrefill.csproj in the working dir.

Typically, for development you will want to run the project in Debug mode. This mode will run dramatically slower than Release, however it will leave useful debugging information in the compiled assembly. Running the following will detect and compile any changes, and then execute the project:

dotnet run

The above is analogous to running ./EpicPrefill.exe without any parameters. To instead supply parameters :

dotnet run -- prefill --all

Alternatively, to run the project at full speed with all compilation optimizations enabled, add the additional --configuration Release flag:

dotnet run --configuration Release

Executing Unit Tests

To compile and run all tests in the entire repo, run the following command:

dotnet test