dotnet / dotnet/msbuild

[MSBuild]::MakeRelative works completely incorrect with Unix paths that contains "up-directory" symbol in.

Open
#2,166 1 comment 1 reaction 0 assignees View on GitHub
triaged
Dominant language
C#
Stars
5.5k
Forks
1.5k
Avg merge
1d 8h
Merged PRs (30d)
141

Description

In case
`[MSBuild]::MakeRelative("\foo\bar\..\abc\cde\", "\foo\bar\..\abc\fff\ggg.hh")`

the function returns
`\foo\bar\abc\fff\ggg.hh`

When accorring to https://msdn.microsoft.com/en-us/library/dd633440.aspx the correct result has to be
`..\fff\ggg.hh`

Note I am using '\\' as directory separator because #429 though it has to be '/' for Unix systems.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.