Skip to content

Commit

Permalink
Ensure notices build command only creates a NOTICE.txt (#84)
Browse files Browse the repository at this point in the history
  • Loading branch information
Mpdreamz authored Nov 20, 2024
1 parent 9a8ee60 commit e4ea418
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 2 deletions.
24 changes: 24 additions & 0 deletions NOTICE.txt
Original file line number Diff line number Diff line change
Expand Up @@ -307,6 +307,30 @@ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

License notice for ini-parser-netstandard (v2.5.2)
------------------------------------
The MIT License (MIT)

Copyright (c) 2008 Ricardo Amores Hernández

Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.


License notice for Markdig (v0.37.0)
------------------------------------
Copyright (c) 2018-2019, Alexandre Mutel
Expand Down
5 changes: 3 additions & 2 deletions build/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,9 @@ dotnet publish {source} -c Release -o .artifacts/publish \

app.Add("notices", async Task<int> (Cancel ctx) =>
{
var packages = await "dotnet thirdlicense --project src/docs-builder/docs-builder.csproj --output NOTICE.txt";
var packageLines = packages.Split(Environment.NewLine).Where(l=>l.StartsWith("+"));
await File.WriteAllTextAsync("NOTICE.txt",
$"""
Elastic Documentation Tooling
Expand All @@ -41,8 +44,6 @@ Copyright 2024-{DateTime.UtcNow.Year} Elasticsearch B.V.
""", ctx);
var packages = await "dotnet thirdlicense --project src/docs-builder/docs-builder.csproj";
var packageLines = packages.Split(Environment.NewLine).Where(l=>l.StartsWith("+"));
Console.WriteLine("Package lines:");
foreach (var line in packageLines)
Expand Down

0 comments on commit e4ea418

Please sign in to comment.