Feature Request: Add ability to execute custom script before tools.ps1 (/.sh)
- Dominant language
- C#
- Stars
- 729
- Forks
- 397
- Avg merge
- 3d 15m
- Merged PRs (30d)
- 149
Description
- [ ] This issue is blocking
- [ ] This issue is causing unreasonable pain
- [x] This issue is causing reasonable pain
Every time a .NET repo syncs a new build with an update in the global.json, a new version of the SDK and runtimes is downloaded to the reporoot\.dotnet folder. For the SDK repo in particular, we end up copying that folder into a redist location and then copying our built bits on top of that version of the SDK. This is because we don't build everything we need for a working SDK to use for testing and so use the rest from the SDK installed by global.json.
This can lead to bloat...a lot of bloat. I've had dozens of versions of the runtime and sdk end up in the .dotnet folder and my redist dogfood folder currently has 54 runtimes. We're starting to have more scenarios where we want to edit things based on the runtime version that came from the SDK but today, we don't know what version that is and the folder has too many for us to know for sure.
Tentative plan:
1. add runtime version information into a .runtimesversion file in the SDK install
2. Modify the SDK repo to target those specific versions from the stage 0 SDK
3. clean out old SDKs/runtimes in the .dotnet and redist folder that don't match (if we can).
It'd be simpler though if we could just clear those folders out before running tools.ps1 as it would be a simple matter of deleting everything and letting tools.ps1 bring them back
### Release Note Category
- [ ] Feature changes/additions
- [ ] Bug fixes
- [ ] Internal Infrastructure Improvements
### Release Note Description
Contributor guide
Assessment
This issue has not been assessed yet.