dotnet / dotnet/msbuild

Importing files in directories above me

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

Description

When I'm trying to import a file with a path relative to the file which will add the `` element I've always felt comfortable using relative paths. For example if I want to import the Directory.Build.props file in the directory above the current file I will do the following:

``` xml

```

This functions and hasn't had any negative consequences. At least none that I'm aware of. Yet when I see [MSBuild documentation](https://docs.microsoft.com/en-us/visualstudio/msbuild/customize-your-build) or digging through older build files I often see the following pattern:

``` xml

```

This seems needlessly complex. Yet this is done often enough that it must be for a reason. What scenario is this protecting against that I'm missing with my simple import elements?

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.