Skip to content

Commit 332f7ec

Browse files
committed
Document inclusion of SL v2 in readme
This comes from the bump to ThisAssembly.Constants 2.0.6, which now considers GitInfo as a direct reference and will trigger the in-IDE requirement of sponsorship (direct, indirect or implicit).
1 parent 4d750af commit 332f7ec

File tree

4 files changed

+22
-8
lines changed

4 files changed

+22
-8
lines changed

readme.md

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,14 +11,16 @@ Git Info from MSBuild, C# and VB
1111
[![License](https://img.shields.io/:license-MIT-blue.svg)](https://opensource.org/licenses/mit-license.php)
1212
[![Build status](https://ci.appveyor.com/api/projects/status/p9e5xdd86vnfe0q8?svg=true)](https://ci.appveyor.com/project/MobileEssentials/gitinfo)
1313

14-
## Usage
15-
16-
After installing via [NuGet](https://www.nuget.org/packages/GitInfo):
14+
Install via [NuGet](https://www.nuget.org/packages/GitInfo):
1715

1816
```pwsh
1917
PM> Install-Package GitInfo
2018
```
2119

20+
<!-- include https://github.com/devlooped/.github/raw/main/sponsorlinkr.md -->
21+
22+
## Usage
23+
<!-- #content -->
2224
By default, if the containing project is a C#, F# or VB project, a compile-time generated
2325
source file will contain all the git information and can be accessed from anywhere within
2426
the assembly, as constants in a `ThisAssembly` (partial) class and its nested `Git` static class:
@@ -105,8 +107,7 @@ VB:
105107
> the relevant properties to false: `GenerateAssemblyVersionAttribute`,
106108
> `GenerateAssemblyFileVersionAttribute` and `GenerateAssemblyInformationalVersionAttribute`.
107109
108-
109-
MSBuild:
110+
You can also just build your own versioning logic in a target that depends on GitInfo using plain MSBuild:
110111

111112
```xml
112113
<PropertyGroup>
@@ -255,7 +256,7 @@ to customize the behavior:
255256
included in the [NuGet package](https://www.nuget.org/packages/GitInfo)
256257
- 100% incremental build-friendly and high-performing (all proper Inputs/Outputs in place, smart caching of Git info, etc.)
257258

258-
259+
<!-- #content -->
259260
<!-- include https://github.com/devlooped/sponsors/raw/main/footer.md -->
260261
# Sponsors
261262

src/Directory.targets

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,14 @@
11
<Project InitialTargets="SetLocalVersion">
22

3+
<PropertyGroup>
4+
<Description>
5+
$(Description)
6+
7+
> This project uses SponsorLink to attribute sponsor status (direct, indirect or implicit). For IDE usage, sponsor status is required.
8+
> IDE-only warnings will be emitted after a grace period otherwise. Learn more at https://github.com/devlooped#sponsorlink.
9+
</Description>
10+
</PropertyGroup>
11+
312
<Target Name="SetLocalVersion" Condition="!$(CI)">
413
<GetVersion>
514
<Output TaskParameter="Version" PropertyName="Version" />

src/GitInfo/GitInfo.msbuildproj

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,11 @@
1212
<ItemGroup>
1313
<PackageReference Include="NuGetizer" Version="1.2.3" />
1414
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="8.0.0" PrivateAssets="all" />
15-
<PackageReference Include="ThisAssembly.Constants" Version="2.0.5" Pack="true" TargetFramework="netstandard2.0" />
15+
<PackageReference Include="ThisAssembly.Constants" Version="2.0.6" Pack="true" TargetFramework="netstandard2.0" />
1616
</ItemGroup>
1717
<ItemGroup>
1818
<None Include="build/**/*.*" />
1919
<None Include="buildMultiTargeting/**/*.*" />
2020
<None Include="buildTransitive/**/*.*" />
21-
<None Include="..\..\readme.md" PackagePath="readme.md" />
2221
</ItemGroup>
2322
</Project>

src/GitInfo/readme.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
<!-- include https://github.com/devlooped/.github/raw/main/sponsorlinkr.md -->
2+
<!-- include ../../readme.md#content -->
3+
<!-- include https://github.com/devlooped/sponsors/raw/main/footer.md -->
4+
<!-- prevent expansion via CI markdown includes -->
5+
<!-- exclude -->

0 commit comments

Comments
 (0)