Skip to content

Commit 473b538

Browse files
committed
Fix handling of file:// urls
1 parent 0aeb69f commit 473b538

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

Directory.Build.props

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -246,6 +246,8 @@
246246
<OfficialBaseURL>https://dotnetcli.azureedge.net/dotnet/</OfficialBaseURL>
247247
<!-- Allow overriding the public base URL for Unified Build scenarios to pull assets from a local build. -->
248248
<PublicBaseURL Condition="'$(PublicBaseURL)' == ''">https://dotnetbuilds.azureedge.net/public/</PublicBaseURL>
249+
<!-- MSBuild removes the '//' slashes when passing PublicBaseURL from the outer to the inner build. -->
250+
<PublicBaseURL Condition="$(PublicBaseURL.StartsWith('file:')) and '$(OS)' != 'Windows_NT'">$([System.Text.RegularExpressions.Regex]::Replace('$(PublicBaseURL)', '%28file:\/{1,}%29%28.+%29', 'file:///%242'))</PublicBaseURL>
249251
<InternalBaseURL>https://dotnetbuilds.azureedge.net/internal/</InternalBaseURL>
250252
<!-- Allow overriding where installers are pulled in from previously completed jobs in Unified Build scenarios. -->
251253
<CrossArchitectureInstallerBasePath Condition="'$(CrossArchitectureInstallerBasePath)' == ''">$(InstallersOutputPath)</CrossArchitectureInstallerBasePath>

0 commit comments

Comments
 (0)