Skip to content
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions Tools/CI/Recipes/EditorFunctionalTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,9 @@ protected override IJobBuilder ProduceJob(string jobName, Package package, Platf
.WithDescription(jobName)
.WithPlatform(platform);

if (platform.System == SystemType.Windows)
{
job.WithCommands(c => c.Add(InputSystemSettings.NetfxInstallCmd));
}
job.WithCommands(c => c.Add(platform.System == SystemType.Windows
? InputSystemSettings.DocfxInstallCmdWindows
: InputSystemSettings.DocfxInstallCmdUnix));

job.WithCommands(c => c
.Add(InputSystemSettings.DoctoolsInstallCmd)
Expand Down
7 changes: 3 additions & 4 deletions Tools/CI/Recipes/EditorPerformanceTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,9 @@ protected override IJobBuilder ProduceJob(string jobName, Package package, Platf
.WithDescription(jobName)
.WithPlatform(platform);

if (platform.System == SystemType.Windows)
{
job.WithCommands(c => c.Add(InputSystemSettings.NetfxInstallCmd));
}
job.WithCommands(c => c.Add(platform.System == SystemType.Windows
? InputSystemSettings.DocfxInstallCmdWindows
: InputSystemSettings.DocfxInstallCmdUnix));

job.WithCommands(c => c
.Add(InputSystemSettings.DoctoolsInstallCmd)
Expand Down
7 changes: 3 additions & 4 deletions Tools/CI/Recipes/StandaloneFunctionalTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,9 @@ protected override IJobBuilder ProduceJob(string jobName, Package package, Platf
.WithDescription(jobName)
.WithPlatform(platform);

if (platform.System == SystemType.Windows)
{
job.WithCommands(c => c.Add(InputSystemSettings.NetfxInstallCmd));
}
job.WithCommands(c => c.Add(platform.System == SystemType.Windows
? InputSystemSettings.DocfxInstallCmdWindows
: InputSystemSettings.DocfxInstallCmdUnix));

job.WithCommands(c => c
.Add(InputSystemSettings.DoctoolsInstallCmd)
Expand Down
7 changes: 3 additions & 4 deletions Tools/CI/Recipes/StandaloneIl2CppFunctionalTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,9 @@ protected override IJobBuilder ProduceJob(string jobName, Package package, Platf
.WithDescription(jobName)
.WithPlatform(platform);

if (platform.System == SystemType.Windows)
{
job.WithCommands(c => c.Add(InputSystemSettings.NetfxInstallCmd));
}
job.WithCommands(c => c.Add(platform.System == SystemType.Windows
? InputSystemSettings.DocfxInstallCmdWindows
: InputSystemSettings.DocfxInstallCmdUnix));

job.WithCommands(c => c
.Add(InputSystemSettings.DoctoolsInstallCmd)
Expand Down
7 changes: 3 additions & 4 deletions Tools/CI/Recipes/StandaloneIl2CppPerformanceTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,9 @@ protected override IJobBuilder ProduceJob(string jobName, Package package, Platf
.WithDescription(jobName)
.WithPlatform(platform);

if (platform.System == SystemType.Windows)
{
job.WithCommands(c => c.Add(InputSystemSettings.NetfxInstallCmd));
}
job.WithCommands(c => c.Add(platform.System == SystemType.Windows
? InputSystemSettings.DocfxInstallCmdWindows
: InputSystemSettings.DocfxInstallCmdUnix));

job.WithCommands(c => c
.Add(InputSystemSettings.DoctoolsInstallCmd)
Expand Down
7 changes: 3 additions & 4 deletions Tools/CI/Recipes/StandalonePerformanceTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,9 @@ protected override IJobBuilder ProduceJob(string jobName, Package package, Platf
.WithDescription(jobName)
.WithPlatform(platform);

if (platform.System == SystemType.Windows)
{
job.WithCommands(c => c.Add(InputSystemSettings.NetfxInstallCmd));
}
job.WithCommands(c => c.Add(platform.System == SystemType.Windows
? InputSystemSettings.DocfxInstallCmdWindows
: InputSystemSettings.DocfxInstallCmdUnix));

job.WithCommands(c => c
.Add(InputSystemSettings.DoctoolsInstallCmd)
Expand Down
34 changes: 31 additions & 3 deletions Tools/CI/Settings/InputSystemSettings.cs
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,37 @@ public class InputSystemSettings : AnnotatedSettingsBase
public static readonly string BranchName = "develop";
public static readonly string InputSystemPackageName = "com.unity.inputsystem";

// Command to install .NET Framework 4.7.1 Developer Pack which is used by doctools on Windows.
public static readonly string NetfxInstallCmd = "%GSUDO% choco install netfx-4.7.1-devpack -y --ignore-detected-reboot --ignore-package-codes";
public static readonly string DoctoolsInstallCmd = "git clone --branch \"2.3.0-preview\" git@github.cds.internal.unity3d.com:unity/com.unity.package-manager-doctools.git Packages/com.unity.package-manager-doctools";
// PMDT (Package Manager Doctools) 2.3 has been unmaintained for ~3 years and its bundled DocFX
// started failing intermittently on CI (the "manual" folder silently not being generated) due to
// unrelated tooling backports on the Yamato images. Per USF Docs Engineering guidance, the recommended fix is
// to upgrade to a current PMDT release rather than continue pinning the old version.
//
// NOTE: Starting with PMDT 3.0.0, DocFX is no longer bundled with the package and must be
// installed separately as a dotnet tool. See:
// https://docs.unity3d.com/Packages/com.unity.package-manager-doctools@3.14/manual/installation.html
//
// dotnet SDK availability: confirmed present on package-ci images (Windows, Mac, and Ubuntu) via
// #devs-pets / #devs-ci Slack history - it's a centrally maintained, version-pinned component of
// the image family (e.g. package-ci/ubuntu-22.04:v4 SDK version pinning discussion, and a Windows
// package-ci job observed spawning a .NET 8 subprocess), not something jobs install themselves.
// So no extra .NET SDK install step is needed here.
//
// NuGet source reachability - `dotnet tool install` needs to resolve the docfx package from a feed.
// There's no nuget.config at the repo root (only Tools/CI/nuget.config, which NuGet won't discover
// from here since it only walks upward from the working directory), so we pin --add-source
// explicitly below to Unity's internal Artifactory NuGet proxy - the same source Tools/CI/nuget.config
// uses, and one we know CI agents can already reach since the recipe-regeneration job restores
// packages through it. Default sources (nuget.org) are likely unreachable from these locked-down
// build agents. Still worth confirming on the first real CI run that Artifactory actually mirrors
// the "docfx" package specifically (vs. only packages requested before).
Comment thread
ritamerkl marked this conversation as resolved.
Outdated
public static readonly string DocfxVersion = "2.70.0";
public static readonly string NugetInternalSource = "https://artifactory.prd.it.unity3d.com/artifactory/api/nuget/v3/nuget";

// Installs the DocFX version PMDT 3.x expects, as a dotnet tool, per-platform.
public static readonly string DocfxInstallCmdWindows = $"dotnet tool install docfx --version {DocfxVersion} --tool-path %USERPROFILE%/.pmdt --add-source {NugetInternalSource}";
public static readonly string DocfxInstallCmdUnix = $"dotnet tool install docfx --version {DocfxVersion} --tool-path $HOME/.pmdt --add-source {NugetInternalSource}";

public static readonly string DoctoolsInstallCmd = "git clone --branch \"3.14.8-preview\" git@github.cds.internal.unity3d.com:unity/com.unity.package-manager-doctools.git Packages/com.unity.package-manager-doctools";

public WrenchPackage InputSystemPackage => Wrench.Packages[InputSystemPackageName];

Expand Down
Loading