Skip to content

Commit

Permalink
opentk metapackage
Browse files Browse the repository at this point in the history
  • Loading branch information
frederikja163 committed Mar 19, 2020
1 parent 50ec0cf commit 8a02bc9
Show file tree
Hide file tree
Showing 11 changed files with 48 additions and 13 deletions.
4 changes: 2 additions & 2 deletions OpenTK.nuspec
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@
<projectUrl>https://github.com/opentk/opentk</projectUrl>

<license type="expression">MIT</license>
<icon>icon.png</icon>

<iconUrl>https://api.nuget.org/v3-flatcontainer/opentk/3.1.0/icon</iconUrl>

<description>The Open Toolkit is set of fast, low-level C# bindings for OpenGL, OpenGL ES and OpenAL. It runs on all major platforms and powers hundreds of apps, games and scientific research.</description>

Expand Down
31 changes: 28 additions & 3 deletions build.fsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@ open System.IO
open System.Threading
open Fake.Core
open Fake.DotNet
open Fake.DotNet
open Fake.DotNet
open Fake.DotNet.NuGet
open Fake.IO

#r "paket:
Expand Down Expand Up @@ -265,9 +264,10 @@ Target.create "CreateNuGetPackage" (fun _ ->
let dir = Path.GetDirectoryName proj
let templatePath = Path.Combine(dir, "paket")
let oldTmplCont = File.ReadAllText templatePath
let newTmplCont = oldTmplCont.Insert(oldTmplCont.Length, sprintf "\nversion %s\nauthors %s\ndescription %s"
let newTmplCont = oldTmplCont.Insert(oldTmplCont.Length, sprintf "\nversion \n\t%s\nauthors \n\t%s\nowners \n\t%s\ndescription \n\t%s"
release.NugetVersion
(authors |> List.reduce (fun s a -> s + " " + a))
(authors |> List.reduce (fun s a -> s + " " + a))
description).Replace("#VERSION#", release.NugetVersion)
File.WriteAllText(templatePath + ".template", newTmplCont)
let setParams (p:Paket.PaketPackParams) =
Expand All @@ -280,6 +280,30 @@ Target.create "CreateNuGetPackage" (fun _ ->
Paket.pack setParams
)

Target.create "CreateMetaPackage" (fun _ ->
let notes = release.Notes |> List.reduce (fun s1 s2 -> s1 + "\n" + s2)
let setParams (p:NuGet.NuGetParams) =
{ p with
Version = release.NugetVersion
Authors = authors
Project = project
// Summary = summary
// Description = description
Copyright = copyright
WorkingDir = binDir
OutputPath = nugetDir
// AccessKey = myAccessKey
Publish = false
ReleaseNotes = notes
Tags = tags
Properties = [
"Configuration", Environment.environVarOrDefault "buildMode" "Release"
]
}
Trace.logf "Creating metapackage from opentk.nuspec"
NuGet.NuGet setParams "opentk.nuspec"
)

// ---------
// Release Targets
// ---------
Expand Down Expand Up @@ -337,6 +361,7 @@ open Fake.Core.TargetOperators
// ==> "RunAllTests"
==> "All"
==> "CreateNuGetPackage"
==> "CreateMetaPackage"
==> "ReleaseOnNuGetGallery"
==> "ReleaseOnGithub"
==> "ReleaseOnAll"
Expand Down
1 change: 1 addition & 0 deletions props/common.props
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
<HasCommonProperties>true</HasCommonProperties>
<LangVersion Condition="$(MSBuildProjectExtension.EndsWith('.csproj'))">7.3</LangVersion>
<Copyright>Copyright (c) 2006 - 2018 Stefanos Apostolopoulos ([email protected]) for the Open Toolkit library.</Copyright>
<GenerateDocumentationFile>true</GenerateDocumentationFile>
</PropertyGroup>
<PropertyGroup>
<OpenTKSolutionRoot>$([System.IO.Path]::GetFullPath($(MSBuildThisFileDirectory)\..))</OpenTKSolutionRoot>
Expand Down
3 changes: 2 additions & 1 deletion src/OpenToolkit.Core/paket
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,5 @@ type file
id OpenToolkit.Core
files
bin\Release\netstandard2.0\OpenToolkit.Core.dll ==> lib\netstandard2.0
bin\Release\netstandard2.0\OpenToolkit.Core.xml ==> lib\netstandard2.0
bin\Release\netstandard2.0\OpenToolkit.Core.xml ==> lib\netstandard2.0
bin\Release\netstandard2.0\OpenToolkit.Core.pdb ==> lib\netstandard2.0
1 change: 0 additions & 1 deletion src/OpenToolkit.Graphics/OpenToolkit.Graphics.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,5 @@

<Import Project="..\..\props\common.props" />
<Import Project="..\..\props\nuget-common.props" />
<Import Project="..\..\props\stylecop.props" />

</Project>
4 changes: 3 additions & 1 deletion src/OpenToolkit.Graphics/paket
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,6 @@ dependencies
OpenToolkit.Core ~> #VERSION#
OpenToolkit.Mathematics ~> #VERSION#
files
bin\Release\netstandard2.0\OpenToolkit.Graphics.dll ==> lib\netstandard2.0
bin\Release\netstandard2.0\OpenToolkit.Graphics.dll ==> lib\netstandard2.0
bin\Release\netstandard2.0\OpenToolkit.Graphics.xml ==> lib\netstandard2.0
bin\Release\netstandard2.0\OpenToolkit.Graphics.pdb ==> lib\netstandard2.0
3 changes: 2 additions & 1 deletion src/OpenToolkit.Input/paket
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,5 @@ type file
id OpenToolkit.Input
files
bin\Release\netstandard2.0\OpenToolkit.Input.dll ==> lib\netstandard2.0
bin\Release\netstandard2.0\OpenToolkit.Input.xml ==> lib\netstandard2.0
bin\Release\netstandard2.0\OpenToolkit.Input.xml ==> lib\netstandard2.0
bin\Release\netstandard2.0\OpenToolkit.Input.pdb ==> lib\netstandard2.0
3 changes: 2 additions & 1 deletion src/OpenToolkit.Mathematics/paket
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,5 @@ type file
id OpenToolkit.Mathematics
files
bin\Release\netstandard2.0\OpenToolkit.Mathematics.dll ==> lib\netstandard2.0
bin\Release\netstandard2.0\OpenToolkit.Mathematics.xml ==> lib\netstandard2.0
bin\Release\netstandard2.0\OpenToolkit.Mathematics.xml ==> lib\netstandard2.0
bin\Release\netstandard2.0\OpenToolkit.Mathematics.pdb ==> lib\netstandard2.0
3 changes: 2 additions & 1 deletion src/OpenToolkit.Windowing.Common/paket
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,5 @@ dependencies
OpenToolkit.Mathematics ~> #VERSION#
files
bin\Release\netstandard2.0\OpenToolkit.Windowing.Common.dll ==> lib\netstandard2.0
bin\Release\netstandard2.0\OpenToolkit.Windowing.Common.xml ==> lib\netstandard2.0
bin\Release\netstandard2.0\OpenToolkit.Windowing.Common.xml ==> lib\netstandard2.0
bin\Release\netstandard2.0\OpenToolkit.Windowing.Common.pdb ==> lib\netstandard2.0
4 changes: 3 additions & 1 deletion src/OpenToolkit.Windowing.Desktop/paket
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,7 @@ dependencies
files
bin\Release\netcoreapp3.0\OpenToolkit.Windowing.Desktop.dll ==> lib\netcoreapp3.0
bin\Release\netcoreapp3.0\OpenToolkit.Windowing.Desktop.xml ==> lib\netcoreapp3.0
bin\Release\netcoreapp3.0\OpenToolkit.Windowing.Desktop.pdb ==> lib\netcoreapp3.0
bin\Release\net472\OpenToolkit.Windowing.Desktop.dll ==> lib\net472
bin\Release\net472\OpenToolkit.Windowing.Desktop.xml ==> lib\net472
bin\Release\net472\OpenToolkit.Windowing.Desktop.xml ==> lib\net472
bin\Release\net472\OpenToolkit.Windowing.Desktop.pdb ==> lib\net472
4 changes: 3 additions & 1 deletion src/OpenToolkit.Windowing.GraphicsLibraryFramework/paket
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,7 @@ dependencies
files
bin\Release\netcoreapp3.0\OpenToolkit.Windowing.GraphicsLibraryFramework.dll ==> lib\netcoreapp3.0
bin\Release\netcoreapp3.0\OpenToolkit.Windowing.GraphicsLibraryFramework.xml ==> lib\netcoreapp3.0
bin\Release\netcoreapp3.0\OpenToolkit.Windowing.GraphicsLibraryFramework.pdb ==> lib\netcoreapp3.0
bin\Release\net472\OpenToolkit.Windowing.GraphicsLibraryFramework.dll ==> lib\net472
bin\Release\net472\OpenToolkit.Windowing.GraphicsLibraryFramework.xml ==> lib\net472
bin\Release\net472\OpenToolkit.Windowing.GraphicsLibraryFramework.xml ==> lib\net472
bin\Release\net472\OpenToolkit.Windowing.GraphicsLibraryFramework.pdb ==> lib\net472

0 comments on commit 8a02bc9

Please sign in to comment.