Skip to content

Commit 48b8f36

Browse files
authored
gitversion & nuget configuration (#1)
* added gitversion * set nuget properties
1 parent a5f4af3 commit 48b8f36

9 files changed

Lines changed: 101 additions & 28 deletions

File tree

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,26 @@
1-
<Project Sdk="Microsoft.NET.Sdk">
1+
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
44
<TargetFramework>netstandard2.0</TargetFramework>
55
<RootNamespace>Contiva.CloudInit.ConfigDrive</RootNamespace>
66
<AssemblyName>Contiva.CloudInit.ConfigDrive.Abstractions</AssemblyName>
7+
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
8+
<PackageRequireLicenseAcceptance>true</PackageRequireLicenseAcceptance>
9+
<PackageLicenseUrl>https://github.com/contiva/CloudInit.ConfigDrive/blob/master/LICENSE</PackageLicenseUrl>
10+
<PackageProjectUrl>https://github.com/contiva/CloudInit.ConfigDrive</PackageProjectUrl>
11+
<Copyright>Contiva</Copyright>
12+
<Authors>Contiva</Authors>
13+
<Company>Contiva</Company>
14+
<Product>Contiva.CloudInit.ConfigDrive</Product>
15+
<RepositoryUrl>https://github.com/contiva/CloudInit.ConfigDrive</RepositoryUrl>
16+
717
</PropertyGroup>
818

19+
<ItemGroup>
20+
<PackageReference Include="GitVersionTask" Version="4.0.0-beta0014">
21+
<PrivateAssets>all</PrivateAssets>
22+
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
23+
</PackageReference>
24+
</ItemGroup>
25+
926
</Project>

src/CloudInit.ConfigDrive.Core/CloudInit.ConfigDrive.Core.csproj

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,25 @@
1-
<Project Sdk="Microsoft.NET.Sdk">
1+
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
44
<TargetFramework>netstandard2.0</TargetFramework>
55
<RootNamespace>Contiva.CloudInit.ConfigDrive</RootNamespace>
66
<AssemblyName>Contiva.CloudInit.ConfigDrive.Core</AssemblyName>
7+
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
8+
<PackageRequireLicenseAcceptance>true</PackageRequireLicenseAcceptance>
9+
<PackageLicenseUrl>https://github.com/contiva/CloudInit.ConfigDrive/blob/master/LICENSE</PackageLicenseUrl>
10+
<PackageProjectUrl>https://github.com/contiva/CloudInit.ConfigDrive</PackageProjectUrl>
11+
<Copyright>Contiva</Copyright>
12+
<Authors>Contiva</Authors>
13+
<Company>Contiva</Company>
14+
<Product>Contiva.CloudInit.ConfigDrive</Product>
15+
<RepositoryUrl>https://github.com/contiva/CloudInit.ConfigDrive</RepositoryUrl>
716
</PropertyGroup>
817

918
<ItemGroup>
19+
<PackageReference Include="GitVersionTask" Version="4.0.0-beta0014">
20+
<PrivateAssets>all</PrivateAssets>
21+
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
22+
</PackageReference>
1023
<PackageReference Include="Newtonsoft.Json" Version="11.0.2" />
1124
<PackageReference Include="SimpleInjector" Version="4.3.0" />
1225
<PackageReference Include="YamlDotNet" Version="5.0.1" />

src/CloudInit.ConfigDrive.NoCloud/CloudInit.ConfigDrive.NoCloud.csproj

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,25 @@
1-
<Project Sdk="Microsoft.NET.Sdk">
1+
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
44
<TargetFramework>netstandard2.0</TargetFramework>
55
<AssemblyName>Contiva.CloudInit.ConfigDrive.NoCloud</AssemblyName>
66
<RootNamespace>Contiva.CloudInit.ConfigDrive</RootNamespace>
7+
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
8+
<PackageRequireLicenseAcceptance>true</PackageRequireLicenseAcceptance>
9+
<PackageLicenseUrl>https://github.com/contiva/CloudInit.ConfigDrive/blob/master/LICENSE</PackageLicenseUrl>
10+
<PackageProjectUrl>https://github.com/contiva/CloudInit.ConfigDrive</PackageProjectUrl>
11+
<Copyright>Contiva</Copyright>
12+
<Authors>Contiva</Authors>
13+
<Company>Contiva</Company>
14+
<Product>Contiva.CloudInit.ConfigDrive</Product>
15+
<RepositoryUrl>https://github.com/contiva/CloudInit.ConfigDrive</RepositoryUrl>
716
</PropertyGroup>
817

918
<ItemGroup>
19+
<PackageReference Include="GitVersionTask" Version="4.0.0-beta0014">
20+
<PrivateAssets>all</PrivateAssets>
21+
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
22+
</PackageReference>
1023
<PackageReference Include="Microsoft.CSharp" Version="4.5.0" />
1124
</ItemGroup>
1225

src/CloudInit.ConfigDrive.WindowsImaging/CloudInit.ConfigDrive.WindowsImaging.csproj

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,25 @@
44
<TargetFramework>net471</TargetFramework>
55
<RootNamespace>Contiva.CloudInit.ConfigDrive</RootNamespace>
66
<AssemblyName>Contiva.CloudInit.ConfigDrive.WindowsImaging</AssemblyName>
7+
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
8+
<PackageRequireLicenseAcceptance>true</PackageRequireLicenseAcceptance>
9+
<PackageLicenseUrl>https://github.com/contiva/CloudInit.ConfigDrive/blob/master/LICENSE</PackageLicenseUrl>
10+
<PackageProjectUrl>https://github.com/contiva/CloudInit.ConfigDrive</PackageProjectUrl>
11+
<Copyright>Contiva</Copyright>
12+
<Authors>Contiva</Authors>
13+
<Company>Contiva</Company>
14+
<Product>Contiva.CloudInit.ConfigDrive</Product>
15+
<RepositoryUrl>https://github.com/contiva/CloudInit.ConfigDrive</RepositoryUrl>
16+
717
</PropertyGroup>
818

19+
<ItemGroup>
20+
<PackageReference Include="GitVersionTask" Version="4.0.0-beta0014">
21+
<PrivateAssets>all</PrivateAssets>
22+
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
23+
</PackageReference>
24+
</ItemGroup>
25+
926
<ItemGroup>
1027
<ProjectReference Include="..\CloudInit.ConfigDrive.Core\CloudInit.ConfigDrive.Core.csproj" />
1128
<ProjectReference Include="..\Windows.ImagingApi\Windows.ImagingApi.csproj" />

src/CloudInit.ConfigDrive/CloudInit.ConfigDrive.csproj

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,18 @@
1-
<Project Sdk="Microsoft.NET.Sdk">
1+
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
44
<TargetFramework>netstandard2.0</TargetFramework>
55
<AssemblyName>Contiva.CloudInit.ConfigDrive</AssemblyName>
66
<RootNamespace>Contiva.CloudInit.ConfigDrive</RootNamespace>
7+
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
8+
<PackageRequireLicenseAcceptance>true</PackageRequireLicenseAcceptance>
9+
<PackageLicenseUrl>https://github.com/contiva/CloudInit.ConfigDrive/blob/master/LICENSE</PackageLicenseUrl>
10+
<PackageProjectUrl>https://github.com/contiva/CloudInit.ConfigDrive</PackageProjectUrl>
11+
<Copyright>Contiva</Copyright>
12+
<Authors>Contiva</Authors>
13+
<Company>Contiva</Company>
14+
<Product>Contiva.CloudInit.ConfigDrive</Product>
15+
<RepositoryUrl>https://github.com/contiva/CloudInit.ConfigDrive</RepositoryUrl>
716
</PropertyGroup>
817

918
<ItemGroup>
@@ -15,4 +24,11 @@
1524
<Folder Include="Processing\" />
1625
</ItemGroup>
1726

27+
<ItemGroup>
28+
<PackageReference Include="GitVersionTask" Version="4.0.0-beta0014">
29+
<PrivateAssets>all</PrivateAssets>
30+
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
31+
</PackageReference>
32+
</ItemGroup>
33+
1834
</Project>

src/GenConfigDrive/GenConfigDrive.csproj

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,10 @@
88

99
<ItemGroup>
1010
<PackageReference Include="CommandLineParser" Version="2.3.0" />
11+
<PackageReference Include="GitVersionTask" Version="4.0.0-beta0014">
12+
<PrivateAssets>all</PrivateAssets>
13+
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
14+
</PackageReference>
1115
</ItemGroup>
1216

1317
<ItemGroup>
Lines changed: 4 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,35 +1,15 @@
11
using System.Reflection;
2-
using System.Runtime.CompilerServices;
3-
using System.Runtime.InteropServices;
42

53
// General Information about an assembly is controlled through the following
64
// set of attributes. Change these attribute values to modify the information
75
// associated with an assembly.
8-
[assembly: AssemblyTitle("IMAPI .NET Interop")]
6+
[assembly: AssemblyTitle("Windows Imaging Interop")]
97
[assembly: AssemblyDescription("")]
108
[assembly: AssemblyConfiguration("")]
11-
[assembly: AssemblyCompany("Microsoft Corporation")]
12-
[assembly: AssemblyProduct("Image Mastering API")]
13-
[assembly: AssemblyCopyright("Copyright (c) Microsoft Corporation. All rights reserved.")]
9+
[assembly: AssemblyCompany("Contiva Software GmbH / Microsoft Corporation")]
10+
[assembly: AssemblyProduct("Image Mastering API Interop by Contiva")]
11+
[assembly: AssemblyCopyright("Copyright (c) Contiva Software GmbH and Microsoft Corporation. All rights reserved.")]
1412
[assembly: AssemblyTrademark("")]
1513
[assembly: AssemblyCulture("")]
1614

17-
// Setting ComVisible to false makes the types in this assembly not visible
18-
// to COM components. If you need to access a type in this assembly from
19-
// COM, set the ComVisible attribute to true on that type.
20-
[assembly: ComVisible(true)]
2115

22-
// The following GUID is for the ID of the typelib if this project is exposed to COM
23-
[assembly: Guid("8cfe2f71-debf-4515-b82d-8d56ed367c75")]
24-
25-
// Version information for an assembly consists of the following four values:
26-
//
27-
// Major Version
28-
// Minor Version
29-
// Build Number
30-
// Revision
31-
//
32-
// You can specify all the values or you can default the Revision and Build Numbers
33-
// by using the '*' as shown below:
34-
[assembly: AssemblyVersion("1.0.*")]
35-
[assembly: AssemblyFileVersion("1.0.0.0")]

src/Windows.ImagingApi/Windows.ImagingApi.csproj

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="15.0">
2+
<Import Project="..\..\packages\UtilPack.NuGet.MSBuild.2.4.0\build\UtilPack.NuGet.MSBuild.props" Condition="Exists('..\..\packages\UtilPack.NuGet.MSBuild.2.4.0\build\UtilPack.NuGet.MSBuild.props')" />
23
<PropertyGroup>
34
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
45
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
@@ -29,6 +30,8 @@
2930
<IsWebBootstrapper>false</IsWebBootstrapper>
3031
<UseApplicationTrust>false</UseApplicationTrust>
3132
<BootstrapperEnabled>true</BootstrapperEnabled>
33+
<NuGetPackageImportStamp>
34+
</NuGetPackageImportStamp>
3235
</PropertyGroup>
3336
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
3437
<DebugSymbols>true</DebugSymbols>
@@ -119,4 +122,12 @@
119122
<ProjectExtensions>
120123
<VisualStudio AllowExistingFolder="true" />
121124
</ProjectExtensions>
125+
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
126+
<PropertyGroup>
127+
<ErrorText>This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
128+
</PropertyGroup>
129+
<Error Condition="!Exists('..\..\packages\UtilPack.NuGet.MSBuild.2.4.0\build\UtilPack.NuGet.MSBuild.props')" Text="$([System.String]::Format('$(ErrorText)', '..\..\packages\UtilPack.NuGet.MSBuild.2.4.0\build\UtilPack.NuGet.MSBuild.props'))" />
130+
<Error Condition="!Exists('..\..\packages\GitVersionTask.4.0.0-beta0014\build\GitVersionTask.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\..\packages\GitVersionTask.4.0.0-beta0014\build\GitVersionTask.targets'))" />
131+
</Target>
132+
<Import Project="..\..\packages\GitVersionTask.4.0.0-beta0014\build\GitVersionTask.targets" Condition="Exists('..\..\packages\GitVersionTask.4.0.0-beta0014\build\GitVersionTask.targets')" />
122133
</Project>
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<packages>
3+
<package id="GitVersionTask" version="4.0.0-beta0014" targetFramework="net452" developmentDependency="true" />
34
<package id="JetBrains.Annotations" version="2018.2.1" targetFramework="net471" />
5+
<package id="UtilPack.NuGet.MSBuild" version="2.4.0" targetFramework="net452" developmentDependency="true" />
46
</packages>

0 commit comments

Comments
 (0)