Skip to content

Commit

Permalink
⬆️ Bump files with dotnet-file sync
Browse files Browse the repository at this point in the history
# devlooped/oss

- Dynamically fetch devlooped JWK from github devlooped/oss@55124bc
- Remove dependency on ThisAssembly devlooped/oss@c879f25
- Add targets for inclusion from tests devlooped/oss@81ba912
- Fix path to jwk.ps1 alongside the SponsorLink.targets devlooped/oss@c4830fc
- Fix scenario where multiple packages share product name devlooped/oss@23f83bd
- Rename sample assemblies for nicer display devlooped/oss@93df7c7
- SponsorLink-enabled analyzers need copylocal devlooped/oss@7593657
- Minor code simplification devlooped/oss@cf154d5
- Improve versioning of sample package devlooped/oss@3b943f5
  • Loading branch information
devlooped-bot authored and kzu committed Jun 25, 2024
1 parent 3948cf8 commit 3614d9b
Show file tree
Hide file tree
Showing 22 changed files with 428 additions and 155 deletions.
103 changes: 59 additions & 44 deletions .netconfig
Original file line number Diff line number Diff line change
Expand Up @@ -128,8 +128,8 @@
skip
[file "src/SponsorLink/Analyzer/Analyzer.csproj"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/Analyzer/Analyzer.csproj
sha = 7cda4a18313b0b38b26c0152e1007cdbb9b6ba3a
etag = d9444fa36daa8f4ff8f06fc2f9f600dbd8032f25ff58542d3b96676e0305677e
sha = 93df7c7ec34f83ae58efbf213624d5ea31fe3c41
etag = f76e33fde812244a275b95c8815101f6f87d144a5305a2c1f0f631f770d91920
weak
[file "src/SponsorLink/Analyzer/Properties/launchSettings.json"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/Analyzer/Properties/launchSettings.json
Expand All @@ -138,8 +138,8 @@
weak
[file "src/SponsorLink/Analyzer/StatusReportingAnalyzer.cs"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/Analyzer/StatusReportingAnalyzer.cs
sha = a0ae7272f31c766ebb129ea38c11c01df93b6b5d
etag = 23d4cd16294974d85164fc26d6a7e2ae52698f23a62463db5025d69d9c166dc5
sha = c879f25bf483086725c8a29f104555644e6ee542
etag = cde10b763b87a3987e86cca2292c9afc7637d2113b9921e79492b6a31620bbb4
weak
[file "src/SponsorLink/Analyzer/buildTransitive/SponsorableLib.targets"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/Analyzer/buildTransitive/SponsorableLib.targets
Expand All @@ -148,8 +148,8 @@
weak
[file "src/SponsorLink/Directory.Build.props"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/Directory.Build.props
sha = a0ae7272f31c766ebb129ea38c11c01df93b6b5d
etag = 6823e1e914ecedd174276e3d53517cc0b332bb47c56402a9512cfa6aeeeb067e
sha = 3b943f5aa59f33141d1c0fffcb215446d594ad53
etag = 0c7737411744012078642dbfc174af3f2ac7dc9f7b8ea4423981ae38753a5be4
weak
[file "src/SponsorLink/Directory.Build.targets"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/Directory.Build.targets
Expand All @@ -158,8 +158,8 @@
weak
[file "src/SponsorLink/Library/Library.csproj"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/Library/Library.csproj
sha = a0ae7272f31c766ebb129ea38c11c01df93b6b5d
etag = 3720f8ae0605aa64df8f6c1d9769969162175b79c93a21024653f210a42348e6
sha = 93df7c7ec34f83ae58efbf213624d5ea31fe3c41
etag = 56233a536fb38edd75f66f6a9a9e6044eb227a0b58fb791495ff88e43649feb7
weak
[file "src/SponsorLink/Library/MyClass.cs"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/Library/MyClass.cs
Expand All @@ -173,8 +173,8 @@
weak
[file "src/SponsorLink/SponsorLink.targets"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/SponsorLink.targets
sha = 7cda4a18313b0b38b26c0152e1007cdbb9b6ba3a
etag = d725bd9cfa33f35224e91748f64237e4dc66270f7e5ec7c835b78164531ae3db
sha = 759365751e6529049a3df5701f85aecb51189289
etag = 6e3955b7233c5c2000b9adf1bb281e74e7fb08813e17b3ef10fd8b5d50f9fb4d
weak
[file "src/SponsorLink/SponsorLink/AppDomainDictionary.cs"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/SponsorLink/AppDomainDictionary.cs
Expand All @@ -183,8 +183,8 @@
weak
[file "src/SponsorLink/SponsorLink/DiagnosticsManager.cs"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/SponsorLink/DiagnosticsManager.cs
sha = b2a11faac6c1c300bce8c1d45f95b585c19f2953
etag = 9f289f45169f35916fff1857840d4118ed134215639d6dae9016dc62004291a5
sha = cf154d5d9c2ac3dad56e95da04effdad64409471
etag = 7ac9738f71cafd15dbb347bc9d83468b0691d0b0888cc82e35c161fd1f2d48eb
weak
[file "src/SponsorLink/SponsorLink/ManifestStatus.cs"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/SponsorLink/ManifestStatus.cs
Expand All @@ -193,28 +193,18 @@
weak
[file "src/SponsorLink/SponsorLink/SponsorLink.cs"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/SponsorLink/SponsorLink.cs
sha = 4fca946c3201d90d30e2183f699c850dcc1bf8d5
etag = 96e1b1b28bfb2372bd5ffcc6bdef65ee926822b3489ce65be4e5a400884dce21
sha = 55124bc610b2dcad9efb343bdffc79c959170593
etag = 28178198489bf9b72f8a400563950194a06f7ce55ff4a016535eb1be35fa70b8
weak
[file "src/SponsorLink/SponsorLink/SponsorLink.csproj"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/SponsorLink/SponsorLink.csproj
sha = a0ae7272f31c766ebb129ea38c11c01df93b6b5d
etag = ffaea0b580d8dccd672e749a5efd11fda318c484ca4a34428ff81524ec80ec4b
weak
[file "src/SponsorLink/SponsorLink/SponsorLink.es.resx"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/SponsorLink/SponsorLink.es.resx
sha = 8d29f013595aab6d965f1b91eb8b0ecaa0246366
etag = 7f623861748c4e7f534fa2118eb66ad3056fd5b28cd5d1d19e9348d0236ffe29
weak
[file "src/SponsorLink/SponsorLink/SponsorLink.resx"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/SponsorLink/SponsorLink.resx
sha = 8d29f013595aab6d965f1b91eb8b0ecaa0246366
etag = 47a7b843e07a8ec858579f435b59548056b14d00d6653dc41ef5807613925f31
sha = c879f25bf483086725c8a29f104555644e6ee542
etag = 997b08082f85a491be7a68805d7811e65e1474a6e7d49cbe927617f7035d21e1
weak
[file "src/SponsorLink/SponsorLink/SponsorLinkAnalyzer.cs"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/SponsorLink/SponsorLinkAnalyzer.cs
sha = b2a11faac6c1c300bce8c1d45f95b585c19f2953
etag = fc96f7f5642cbf69b35b7e8de1756822580315f0cee61e47da3b2b1b03f68e1a
sha = 23f83bd6b1f0fe13ac02bf464377f576652fec97
etag = 5f9823d1bf83f7d28e5809e0a08d942fb2c444f4653ca5b035d500ebef2ead15
weak
[file "src/SponsorLink/SponsorLink/SponsorStatus.cs"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/SponsorLink/SponsorStatus.cs
Expand All @@ -226,25 +216,15 @@
sha = a0ae7272f31c766ebb129ea38c11c01df93b6b5d
etag = 2f923a97081481a6a264d63c8ff70ce5ba65c3dbaf7ea078cbe1388fb0868e1c
weak
[file "src/SponsorLink/SponsorLink/ThisAssembly.cs"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/SponsorLink/ThisAssembly.cs
sha = b2a11faac6c1c300bce8c1d45f95b585c19f2953
etag = 978269025f58e2bae872af25fdfd94659e234e8365e3014c18b1b20fdcd155bf
weak
[file "src/SponsorLink/SponsorLink/Tracing.cs"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/SponsorLink/Tracing.cs
sha = a0ae7272f31c766ebb129ea38c11c01df93b6b5d
etag = 22e32872cafd080bcd5ac9084355578ef70910c8e494602ead365139dcbf40c0
weak
[file "src/SponsorLink/SponsorLink/buildTransitive/Devlooped.Sponsors.targets"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/SponsorLink/buildTransitive/Devlooped.Sponsors.targets
sha = 8d29f013595aab6d965f1b91eb8b0ecaa0246366
etag = c7abdd1f840a32948afa15fce5ef5c22f1a29fb8394d265b7c9cbf646a2030bf
weak
[file "src/SponsorLink/SponsorLink/devlooped.pub.jwk"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/SponsorLink/devlooped.pub.jwk
sha = a0ae7272f31c766ebb129ea38c11c01df93b6b5d
etag = cf884781ff88b4d096841e3169282762a898b2050c9b5dac0013bc15bdbee267
sha = 55124bc610b2dcad9efb343bdffc79c959170593
etag = 46842d44ece3d55285bc30a6b22ac21c1c35d3b0c451aa5285d4ca4564b8698c
weak
[file "src/SponsorLink/SponsorLink/sponsorable.md"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/SponsorLink/sponsorable.md
Expand Down Expand Up @@ -278,8 +258,8 @@
weak
[file "src/SponsorLink/Tests/Sample.cs"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/Tests/Sample.cs
sha = e732f6a2c44a2f7940a1868a92cd66523f74ed24
etag = db968d1d665b77a17e13bc7ca3d43ea65ed05cbebc18669f1b607ebe0e38a59a
sha = c879f25bf483086725c8a29f104555644e6ee542
etag = c4ed1e041d1ec816710757790aaa6688e3756870cfd98ba7e6c7b5103ce3a9ba
weak
[file "src/SponsorLink/Tests/SponsorLinkTests.cs"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/Tests/SponsorLinkTests.cs
Expand All @@ -293,11 +273,46 @@
weak
[file "src/SponsorLink/Tests/Tests.csproj"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/Tests/Tests.csproj
sha = a0ae7272f31c766ebb129ea38c11c01df93b6b5d
etag = 237409e155202ec1b845593195d30057a949b2b18ae46a575e4cf480e4e2c8fe
sha = c879f25bf483086725c8a29f104555644e6ee542
etag = 31d33feb5860cd6df71ee2d6f3ca6d8fdc9e6535bea8caa97300421c0502246e
weak
[file "src/SponsorLink/readme.md"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/readme.md
sha = 827a1d18bf0245978d81bcd3d52e9e6f1584d1ef
etag = 079b4aedba2aa9851e609b569f25c55db8d5922e3dbb1adc22611ce4d6cfe465
weak
[file "src/SponsorLink/Library/readme.md"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/Library/readme.md
sha = 55124bc610b2dcad9efb343bdffc79c959170593
etag = 5002ac8c5bbeee60c13937a32c1b6c1a5dbf0065617c8f2550e6eca6fded256d
weak
[file "src/SponsorLink/SponsorLink.Tests.targets"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/SponsorLink.Tests.targets
sha = 81ba912310dd4b723c7a0103a76cb71b183983b1
etag = cf6deba5b5cdadb5b2ea6b8533331da49afd3c841db2932a45618627ffc4ff9a
weak
[file "src/SponsorLink/SponsorLink/Resources.es.resx"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/SponsorLink/Resources.es.resx
sha = c879f25bf483086725c8a29f104555644e6ee542
etag = c0a05bb5efedf8e30a73ab96678579ad33832e4a4aec75d3b596b47f248c23f5
weak
[file "src/SponsorLink/SponsorLink/Resources.resx"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/SponsorLink/Resources.resx
sha = c879f25bf483086725c8a29f104555644e6ee542
etag = fcb46a86511cb7996e8dcd1f4e283cea9cd51610b094ac49a7396301730814b0
weak
[file "src/SponsorLink/Tests/Resources.Designer.cs"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/Tests/Resources.Designer.cs
sha = c879f25bf483086725c8a29f104555644e6ee542
etag = 69404ac09238930893fdbc225ae7839b14957e129b4c05f1ef0e7afcc4c91d63
weak
[file "src/SponsorLink/Tests/Resources.resx"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/Tests/Resources.resx
sha = c879f25bf483086725c8a29f104555644e6ee542
etag = 13d1bb8b0de32a8c9b5dbdc806a036ed89d423cd7c0be187b8c56055c9bf7783
weak
[file "src/SponsorLink/jwk.ps1"]
url = https://github.com/devlooped/oss/blob/main/src/SponsorLink/jwk.ps1
sha = c4830fc3b1aa78ec98d1d2ea4fed86ef0b7b803c
etag = f399e05ecb56adaf41d2545171f299a319142b17dd09fc38e452ca8c5d13bd0d
weak
5 changes: 5 additions & 0 deletions src/SponsorLink/Analyzer/Analyzer.csproj
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<AssemblyName>SponsorableLib.Analyzers</AssemblyName>
<TargetFramework>netstandard2.0</TargetFramework>
<IsRoslynComponent>true</IsRoslynComponent>
<PackFolder>analyzers/dotnet/roslyn4.0</PackFolder>
Expand Down Expand Up @@ -29,4 +30,8 @@
<None Update="buildTransitive\SponsorableLib.targets" Pack="true" />
</ItemGroup>

<ItemGroup>
<Compile Remove="C:\Code\devlooped.oss\src\SponsorLink\SponsorLink\ThisAssembly.cs" />
</ItemGroup>

</Project>
1 change: 0 additions & 1 deletion src/SponsorLink/Analyzer/StatusReportingAnalyzer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.Diagnostics;
using static Devlooped.Sponsors.SponsorLink;
using static ThisAssembly.Constants;

namespace Analyzer;

Expand Down
6 changes: 5 additions & 1 deletion src/SponsorLink/Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,11 @@

<!-- Roslyn caches analyzers aggressively so we are better off using a very dynamic version number
for local builds where a quick devloop is key. We bump version every 10 seconds -->
<Version>42.42.$([System.Math]::Floor($([MSBuild]::Divide($([System.DateTime]::Now.TimeOfDay.TotalSeconds), 10))))</Version>
<Epoc>$([System.DateTime]::Parse("2024-03-15"))</Epoc>
<TotalDays>$([System.DateTime]::UtcNow.Subtract($(Epoc)).TotalDays)</TotalDays>
<Days>$([System.Math]::Truncate($(TotalDays)))</Days>
<Seconds>$([System.Math]::Floor($([MSBuild]::Divide($([System.DateTime]::UtcNow.TimeOfDay.TotalSeconds), 10))))</Seconds>
<Version>42.$(Days).$(Seconds)</Version>

<Product>SponsorableLib</Product>
</PropertyGroup>
Expand Down
14 changes: 2 additions & 12 deletions src/SponsorLink/Library/Library.csproj
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<AssemblyName>SponsorableLib</AssemblyName>
<TargetFramework>netstandard2.0</TargetFramework>
<PackNone>true</PackNone>
<PackageId>SponsorableLib</PackageId>
<Description>Sample library incorporating SponsorLink checks</Description>
<PackOnBuild>true</PackOnBuild>
<PublishRepositoryUrl>true</PublishRepositoryUrl>
</PropertyGroup>

<ItemGroup>
Expand All @@ -16,16 +18,4 @@
<ProjectReference Include="..\Analyzer\Analyzer.csproj" ReferenceOutputAssembly="false" OutputType="Analyzer" />
</ItemGroup>

<ItemGroup>
<EmbeddedResource Update="Resources.resx">
<!-- Default to Just Works resources generation. See https://www.cazzulino.com/resources.html -->
<Generator>MSBuild:Compile</Generator>
<StronglyTypedFileName>$(IntermediateOutputPath)\$([MSBuild]::ValueOrDefault('%(RelativeDir)', '').Replace('\', '.').Replace('/', '.'))%(Filename).g$(DefaultLanguageSourceExtension)</StronglyTypedFileName>
<StronglyTypedLanguage>$(Language)</StronglyTypedLanguage>
<StronglyTypedNamespace Condition="'%(RelativeDir)' == ''">$(RootNamespace)</StronglyTypedNamespace>
<StronglyTypedNamespace Condition="'%(RelativeDir)' != ''">$(RootNamespace).$([MSBuild]::ValueOrDefault('%(RelativeDir)', '').Replace('\', '.').Replace('/', '.').TrimEnd('.'))</StronglyTypedNamespace>
<StronglyTypedClassName>%(Filename)</StronglyTypedClassName>
</EmbeddedResource>
</ItemGroup>

</Project>
5 changes: 5 additions & 0 deletions src/SponsorLink/Library/readme.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Sponsorable Library

Example of a library that is available for sponsorship and leverages
[SponsorLink](https://github.com/devlooped/SponsorLink) to remind users
in an IDE (VS/Rider).
38 changes: 38 additions & 0 deletions src/SponsorLink/SponsorLink.Tests.targets
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
<Project>
<!-- For inclusion in test projects that reference analyzers as project references -->

<PropertyGroup>
<CopyLocalLockFileAssemblies>true</CopyLocalLockFileAssemblies>
</PropertyGroup>

<ItemGroup Condition="'$(ManagePackageVersionsCentrally)' == 'true'">
<PackageReference Include="Humanizer.Core" VersionOverride="2.14.1" PrivateAssets="all" Pack="false" />
<PackageReference Include="System.IdentityModel.Tokens.Jwt" VersionOverride="7.6.0" PrivateAssets="all" Pack="false" />
</ItemGroup>

<ItemGroup Condition="'$(ManagePackageVersionsCentrally)' != 'true'">
<PackageReference Include="Humanizer.Core" Version="2.14.1" PrivateAssets="all" Pack="false" />
<PackageReference Include="System.IdentityModel.Tokens.Jwt" Version="7.6.0" PrivateAssets="all" Pack="false" />
</ItemGroup>

<Target Name="AddSponsorLinkAnalyzerDependencies" BeforeTargets="CoreCompile" DependsOnTargets="ResolveLockFileCopyLocalFiles">
<ItemGroup>
<!-- NOTE: keep in sync with ILRepack'ed assemblies as needed -->
<ReferenceCopyLocalAssemblies Include="@(ReferenceCopyLocalPaths)" Condition="'%(Extension)' == '.dll'
And !$([MSBuild]::ValueOrDefault('%(FileName)', '').EndsWith('.resources', StringComparison.OrdinalIgnoreCase))
And !$([MSBuild]::ValueOrDefault('%(FileName)', '').StartsWith('ThisAssembly', StringComparison.OrdinalIgnoreCase))" />
<Analyzer Include="@(ReferenceCopyLocalAssemblies)" Condition="
!$([MSBuild]::ValueOrDefault('%(FileName)', '').StartsWith('Microsoft.CodeAnalysis', StringComparison.OrdinalIgnoreCase)) And
!$([MSBuild]::ValueOrDefault('%(FileName)', '').StartsWith('Microsoft.CSharp', StringComparison.OrdinalIgnoreCase)) And
!$([MSBuild]::ValueOrDefault('%(FileName)', '').StartsWith('System.', StringComparison.OrdinalIgnoreCase))"
/>
<!-- Brings in System/Microsoft.IdentityModel, System.Text.Encodings.Web, System.Text.Json -->
<Analyzer Include="@(ReferenceCopyLocalAssemblies)" Condition="
$([MSBuild]::ValueOrDefault('%(FileName)', '').StartsWith('System.IdentityModel', StringComparison.OrdinalIgnoreCase)) Or
$([MSBuild]::ValueOrDefault('%(FileName)', '').StartsWith('Microsoft.IdentityModel', StringComparison.OrdinalIgnoreCase)) Or
$([MSBuild]::ValueOrDefault('%(FileName)', '').StartsWith('System.Text', StringComparison.OrdinalIgnoreCase))"
/>
</ItemGroup>
</Target>

</Project>
Loading

0 comments on commit 3614d9b

Please sign in to comment.