Skip to content

Conversation

oleksandr-didyk
Copy link
Contributor

@oleksandr-didyk oleksandr-didyk commented Jan 2, 2023

Resolves #932

Additionally created a subscription for the dependency on runtime (disabled until this PR is merged):

https://github.com/dotnet/runtime (.NET 8) ==> 'https://github.com/dotnet/sourcelink' ('main')
  - Id: e02204af-e240-492f-2682-08daecc8f206
  - Update Frequency: EveryWeek
  - Enabled: False
  - Batchable: False
  - PR Failure Notification tags:
  - Merge Policies: []

CC: @MichaelSimons @crummel

@KalleOlaviNiemitalo
Copy link

KalleOlaviNiemitalo commented Jan 2, 2023

Will the title of this PR be copied to the release notes as is? If so, please include "source-build" in it. I totally expected "pre-build detection" to be a new feature that detects if the CI pipeline has run nbgv get-version already and then skips the NBGV tasks during MSBuild.

Uh I suppose I got confused about the repository as well.

@oleksandr-didyk oleksandr-didyk changed the title add pre-build detection add source-build pre-build detection Jan 3, 2023
@oleksandr-didyk oleksandr-didyk changed the title add source-build pre-build detection add source-build pre-built detection Jan 3, 2023
@oleksandr-didyk oleksandr-didyk force-pushed the feat-enable-pre-build-detection branch from fcab584 to c616e6c Compare January 10, 2023 12:22
@mthalman
Copy link
Member

@oleksandr-didyk - Can you give a status on this please? Is there in-progress work or is it blocked or just pending work? Thanks

@oleksandr-didyk oleksandr-didyk force-pushed the feat-enable-pre-build-detection branch from f0df3de to a2e7374 Compare April 11, 2023 10:50
@oleksandr-didyk
Copy link
Contributor Author

@oleksandr-didyk - Can you give a status on this please? Is there in-progress work or is it blocked or just pending work? Thanks

It was initially waiting for the Arcade bump to flow in. The change got into main last week so this PR got unblocked.
I updated it and it should be ready for re-review now

@ViktorHofer
Copy link
Member

OK there's one more PR that I just submitted that will again make things easier and this PRs diff much smaller: #1003. I suggest to also wait for that one.

@oleksandr-didyk oleksandr-didyk force-pushed the feat-enable-pre-build-detection branch 3 times, most recently from c9d7ba3 to 99d65a8 Compare May 4, 2023 14:38
@oleksandr-didyk oleksandr-didyk requested a review from tmat May 4, 2023 14:39
@@ -4,6 +4,7 @@
<TargetFrameworks>$(NetCurrent)</TargetFrameworks>
<!-- Allow tool to roll forward to a newer major version. -->
<RollForward>Major</RollForward>
<ExcludeFromSourceBuild>true</ExcludeFromSourceBuild>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why does this tool need to be excluded from source build? Please add a comment as it isn't clear just from reading the code.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I did it based on the project's description:

<Description>Command line tool for SourceLink testing.</Description>

Since I thought it is a tool used for testing, but reading it again I might be wrong here. Maybe @tmat can clarify it

Additionally

<PackAsToolShimRuntimeIdentifiers>win-x64;win-x86;osx-x64</PackAsToolShimRuntimeIdentifiers>

causes some additional packages to get pulled in that are marked as pre-builts:

    <Usage Id="Microsoft.AspNetCore.App.Runtime.osx-x64" Version="8.0.0-preview.3.23177.8" />
    <Usage Id="Microsoft.AspNetCore.App.Runtime.win-x64" Version="8.0.0-preview.3.23177.8" />
    <Usage Id="Microsoft.AspNetCore.App.Runtime.win-x86" Version="8.0.0-preview.3.23177.8" />
    <Usage Id="Microsoft.NETCore.App.Host.osx-x64" Version="8.0.0-preview.3.23174.8" />
    <Usage Id="Microsoft.NETCore.App.Host.win-x64" Version="8.0.0-preview.3.23174.8" />
    <Usage Id="Microsoft.NETCore.App.Host.win-x86" Version="8.0.0-preview.3.23174.8" />
    <Usage Id="Microsoft.NETCore.App.Runtime.osx-x64" Version="8.0.0-preview.3.23174.8" />
    <Usage Id="Microsoft.NETCore.App.Runtime.win-x64" Version="8.0.0-preview.3.23174.8" />
    <Usage Id="Microsoft.NETCore.App.Runtime.win-x86" Version="8.0.0-preview.3.23174.8" />

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It should be included. This is not a shipping product yet but it is meant to be. It's for customers to test that their binaries have correct Source Link.

Copy link
Contributor Author

@oleksandr-didyk oleksandr-didyk May 15, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not a shipping product yet

Can this be done as a separate issue to not block this PR? Or it being excluded for some time is a no-go?
Specifically since the assets pulled in by PackAsToolShimRuntimeIdentifiers are non-Linux; or can this property be simply excluded? (as source-build is Linux-only for now)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IMO if source build repositories currently don't depend on the tool, it shouldn't be an issue to exclude it for now and track enabling it.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Created an issue for it -> #1028

@oleksandr-didyk oleksandr-didyk force-pushed the feat-enable-pre-build-detection branch from d790a53 to 81716f5 Compare May 15, 2023 16:08
@tmat tmat merged commit d6c5a50 into dotnet:main May 16, 2023
Xkonti added a commit to Xkonti/smart-migrations-net that referenced this pull request Aug 13, 2025
Updated
[Microsoft.SourceLink.GitHub](https://github.com/dotnet/sourcelink) from
1.1.1 to 8.0.0.

<details>
<summary>Release notes</summary>

_Sourced from [Microsoft.SourceLink.GitHub's
releases](https://github.com/dotnet/sourcelink/releases)._

## 8.0.0

## What's Changed

**Source Link is now included in .NET SDK 8 and enabled by default.
Projects that migrate to .NET SDK 8 do not need to reference Source Link
packages explicitly via `PackageReference` anymore.**

* Add sparse checkout support by @​pakrym in
dotnet/sourcelink#772
* Add support for Gitee by @​luocs in
dotnet/sourcelink#922
* Fix target Input Output as to not interfere with incremental. by
@​yuehuang010 in dotnet/sourcelink#901
* Prepare for inclusion in .NET SDK by @​tmat in
dotnet/sourcelink#988
* Avoid creating source link .json file when no source control mapping
is available by @​tmat in dotnet/sourcelink#989
* Do not report warnings when SourceLink packages are not referenced ex…
by @​tmat in dotnet/sourcelink#991
* Bump version to 8.0 to match SDK by @​tmat in
dotnet/sourcelink#992
* Fix FileWrites by @​tmat in
dotnet/sourcelink#995
* Remove unnecessary <?xml tags by @​ViktorHofer in
dotnet/sourcelink#1013
* Remove unnecessary license header in msbuild by @​ViktorHofer in
dotnet/sourcelink#1014
* Allow multiple Source Link assemblies to be loaded from different
locations by @​tmat in dotnet/sourcelink#1034
* New command-line APIs and `offline` argument by @​NikolaMilosavljevic
in dotnet/sourcelink#1068
* Do not report warning if submodule dir is missing by @​tmat in
dotnet/sourcelink#1078

## New Contributors
* @​MichaelSimons made their first contribution in
dotnet/sourcelink#836
* @​alexperovich made their first contribution in
dotnet/sourcelink#867
* @​ShreyasJejurkar made their first contribution in
dotnet/sourcelink#892
* @​pakrym made their first contribution in
dotnet/sourcelink#772
* @​IanKemp made their first contribution in
dotnet/sourcelink#889
* @​luocs made their first contribution in
dotnet/sourcelink#922
* @​yuehuang010 made their first contribution in
dotnet/sourcelink#901
* @​NikolaMilosavljevic made their first contribution in
dotnet/sourcelink#994
* @​oleksandr-didyk made their first contribution in
dotnet/sourcelink#933
* @​v-chayan made their first contribution in
dotnet/sourcelink#1054

**Full Changelog**:
dotnet/sourcelink@1.1.1...8.0.0

Commits viewable in [compare
view](dotnet/sourcelink@1.1.1...8.0.0).
</details>

[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=Microsoft.SourceLink.GitHub&package-manager=nuget&previous-version=1.1.1&new-version=8.0.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Xkonti <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Enable source-build pre-built detection
7 participants