Remove dependency on CurrentDirectory from all MS-owned tasks
- Dominant language
- C#
- Stars
- 5.5k
- Forks
- 1.5k
- Avg merge
- 1d 13h
- Merged PRs (30d)
- 133
Description
We should clean up at least the tasks that we own to remove the dependency on CurrentDirectory.
Things like this:
https://referencesource.microsoft.com/#PresentationBuildTasks/BuildTasks/Microsoft/Build/Tasks/Windows/MarkupCompilePass1.cs,83
This would move use one step closer to being able to run targets in parallel where possible (currently not possible because tasks depend on Environment.CurrentDirectory and you can't have two different ones simultaneously).
Also it's good for reproducible builds, so that it doesn't matter where you're running the build from. Otherwise we can get stuff like this:

Contributor guide
No contributing guide indexed for this repository
Research direction
Start by auditing the MS-owned tasks, using PresentationBuildTasks/BuildTasks/Microsoft/Build/Tasks/Windows/MarkupCompilePass1.cs around the referenced CurrentDirectory use as an entry point. Identify each task dependency on Environment.CurrentDirectory and define done as removing those dependencies while preserving reproducible, parallel-safe builds.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp
- Domain
- build-system
- Issue type
- Refactor
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100