- Remove nuproj projects and replace with plain nuspec files.
- Update AppVeyor yaml accordingly.
- Replace gitversion with Nerdbank.GitVersioning.
- Rework update dependencies PS to update nuspec instead of nuproj.

Signed-off-by: José Simões <jose.simoes@eclo.solutions>
This commit is contained in:
José Simões 2018-11-07 11:53:05 +00:00
Родитель edc6fd5ca0
Коммит 83ab1ec59c
16 изменённых файлов: 153 добавлений и 286 удалений

Просмотреть файл

@ -1,38 +0,0 @@
next-version: 1.0.0
assembly-versioning-scheme: MajorMinorPatch
assembly-file-versioning-scheme: MajorMinorPatch
assembly-informational-format: '{LegacySemVerPadded}'
build-metadata-padding: 3
legacy-semver-padding: 3
major-version-bump-message: '\+semver:\s?(breaking|major)'
minor-version-bump-message: '\+semver:\s?(feature|minor)'
patch-version-bump-message: '\+semver:\s?(fix|patch)'
branches:
master:
mode: ContinuousDelivery
tag:
increment: Patch
prevent-increment-of-merged-branch-version: true
track-merge-target: false
develop:
regex: dev(elop)?(ment)?$
mode: ContinuousDeployment
tag: preview
increment: Patch
prevent-increment-of-merged-branch-version: false
track-merge-target: true
tracks-release-branches: true
is-release-branch: false
release:
tag: rc
pull-request:
regex: (pull|pull\-requests|pr)[/-]
tag: alpha
mode: ContinuousDelivery
increment: Inherit
prevent-increment-of-merged-branch-version: false
track-merge-target: false
tracks-release-branches: false
is-release-branch: false
ignore:
sha: []

Просмотреть файл

@ -16,6 +16,7 @@ skip_commits:
- 'LICENSE'
- dir/*
- '.gitignore'
- 'azure-pipelines.yml'
build:
verbosity: minimal
@ -44,13 +45,12 @@ init:
- ps: "if($env:APPVEYOR_PULL_REQUEST_NUMBER -eq \"\")\n{\n \n if($env:APPVEYOR_REPO_COMMIT_AUTHOR -eq \"nfbot\" -and $env:APPVEYOR_REPO_COMMIT_MESSAGE_EXTENDED -like \"*[version update]*\")\n {\n # commit was from nfbot AND it's taged as a [version update]\n # OK to skip AppVeyor build \n \"Version update only. Skipping build.\" | Write-Host -BackgroundColor White -ForegroundColor Blue\n Exit-AppveyorBuild\n }\n}"
install:
- set PATH=C:\Ruby%RUBY_VERSION%\bin;%PATH%
- bundle config --local path vendor/bundle
- gem install bundler --quiet --no-ri --no-rdoc
- gem install github_changelog_generator --quiet --no-ri --no-rdoc
# this needs to be replace with the official version and nuget package as soon as it's released
- dotnet tool install -g --version 4.0.0-pullrequest1422-1625 --add-source https://ci.appveyor.com/nuget/gitversion-8nigugxjftrw GitVersion.CommandLine.DotNetCore.Tool
- ps: .\install-vsix-appveyor.ps1
- set PATH=C:\Ruby%RUBY_VERSION%\bin;%PATH%
- bundle config --local path vendor/bundle
- gem install bundler --quiet --no-ri --no-rdoc
- gem install github_changelog_generator --quiet --no-ri --no-rdoc
- dotnet tool install --tool-path . nbgv
- ps: .\install-vsix-appveyor.ps1
before_build:
- ps: >-
@ -59,25 +59,32 @@ before_build:
nuget restore source\nanoFramework.Windows.Devices.Gpio.sln
dotnet-gitversion /l console /output buildserver /updateAssemblyInfo "source\Windows.Devices.Gpio\Properties\AssemblyInfo.cs"
.\nbgv cloud -p source -a -c
build_script:
- ps: >-
msbuild source\nanoFramework.Windows.Devices.Gpio.sln /p:Configuration=Release /logger:"C:\Program Files\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll"
- ps: msbuild source\nanoFramework.Windows.Devices.Gpio.sln /p:PublicRelease=true /p:Configuration=Release /logger:"C:\Program Files\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll"
before_deploy:
- ps: >-
.\nbgv cloud --version=$env:NBGV_SemVer1
$env:MyNuGetVersion = $env:NBGV_NuGetPackageVersion -replace "\-g$env:NBGV_GitCommitIdShort", " "
.\generate-change-log.ps1
- nuget pack source\nanoframework.Windows.Devices.Gpio.nuspec -Version %MyNuGetVersion%
- nuget pack source\nanoframework.Windows.Devices.Gpio.DELIVERABLES.nuspec -Version %MyNuGetVersion%
- ps: >-
.\commit-assemblyinfo-changes.ps1
.\generate-change-log.ps1
Push-AppveyorArtifact $env:APPVEYOR_BUILD_FOLDER\source\Nuget.Windows.Devices.Gpio\bin\Release\nanoFramework.Windows.Devices.Gpio.$env:GitVersion_NuGetVersionV2.nupkg
Push-AppveyorArtifact $env:APPVEYOR_BUILD_FOLDER\nanoFramework.Windows.Devices.Gpio.$env:MyNuGetVersion.nupkg
after_deploy:
# for this environment variable to work here it has to be set in AppVeyor UI
- nuget push source\Nuget.Windows.Devices.Gpio\bin\Release\nanoFramework.Windows.Devices.Gpio.%GitVersion_NuGetVersionV2%.nupkg %MyGetToken% -Source https://www.myget.org/F/nanoframework-dev/api/v2/package
- nuget push source\Nuget.Windows.Devices.Gpio.DELIVERABLES\bin\Release\nanoFramework.Windows.Devices.Gpio.DELIVERABLES.%GitVersion_NuGetVersionV2%.nupkg %MyGetToken% -Source https://www.myget.org/F/nanoframework-dev/api/v2/package
- nuget push nanoFramework.Windows.Devices.Gpio.%MyNuGetVersion%.nupkg %MyGetToken% -Source https://www.myget.org/F/nanoframework-dev/api/v2/package
- nuget push nanoFramework.Windows.Devices.Gpio.DELIVERABLES.%MyNuGetVersion%.nupkg %MyGetToken% -Source https://www.myget.org/F/nanoframework-dev/api/v2/package
# requires APPVEYOR_DISCORD_WEBHOOK_URL enviroment variable set with Discord webhook URL
on_failure:
@ -90,8 +97,6 @@ on_success:
cache:
- source\packages -> **source\packages.config
- C:\ProgramData\chocolatey\bin -> appveyor.yml
- C:\ProgramData\chocolatey\lib -> appveyor.yml
################################################
# override configuration for specific branches
@ -110,9 +115,9 @@ for:
on:
appveyor_repo_tag: true
- provider: GitHub
tag: v$(GitVersion_NuGetVersionV2)
release: nanoFramework Windows.Devices.Gpio Library v$(GitVersion_NuGetVersionV2)
description: 'Check the [changelog](https://github.com/nanoframework/lib-Windows.Devices.Gpio/blob/master/CHANGELOG.md)\n\n## Install from NuGet\n\nThe following NuGet packages are available for download from this release\n\n:package: [.NET](https://www.nuget.org/packages/nanoFramework.Windows.Devices.Gpio/$(GitVersion_NuGetVersionV2)) v$(GitVersion_NuGetVersionV2)'
tag: v$(MyNuGetVersion)
release: nanoFramework Windows.Devices.Gpio Library v$(MyNuGetVersion)
description: 'Check the [changelog](https://github.com/nanoframework/lib-Windows.Devices.Gpio/blob/master/CHANGELOG.md)\n\n## Install from NuGet\n\nThe following NuGet packages are available for download from this release\n\n:package: [.NET](https://www.nuget.org/packages/nanoFramework.Windows.Devices.Gpio/$(MyNuGetVersion)) v$(MyNuGetVersion)'
auth_token:
secure: DNixoFFE+pGlwyhj7McfZoln42vOmj0iY1iNV9zXEr3y0NpXlOIgL8k5ehzlFM1S
artifact:
@ -129,9 +134,9 @@ for:
deploy:
- provider: GitHub
tag: v$(GitVersion_NuGetVersionV2)
release: nanoFramework Windows.Devices.Gpio Library v$(GitVersion_NuGetVersionV2)
description: 'Check the [changelog](https://github.com/nanoframework/lib-Windows.Devices.Gpio/blob/$(appveyor_repo_branch)/CHANGELOG.md)\n\n## Install from nanoFramework MyGet development feed\n\nThe following NuGet packages are available for download from this release\n\npackage: [.NET](https://www.myget.org/feed/nanoframework-dev/package/nuget/nanoFramework.Windows.Devices.Gpio/$(GitVersion_NuGetVersionV2)) v$(GitVersion_NuGetVersionV2)'
tag: v$(MyNuGetVersion)
release: nanoFramework Windows.Devices.Gpio Library v$(MyNuGetVersion)
description: 'Check the [changelog](https://github.com/nanoframework/lib-Windows.Devices.Gpio/blob/$(appveyor_repo_branch)/CHANGELOG.md)\n\n## Install from nanoFramework MyGet development feed\n\nThe following NuGet packages are available for download from this release\n\npackage: [.NET](https://www.myget.org/feed/nanoframework-dev/package/nuget/nanoFramework.Windows.Devices.Gpio/$(MyNuGetVersion)) v$(MyNuGetVersion)'
auth_token:
secure: DNixoFFE+pGlwyhj7McfZoln42vOmj0iY1iNV9zXEr3y0NpXlOIgL8k5ehzlFM1S
artifact:
@ -153,9 +158,9 @@ for:
on:
appveyor_repo_tag: true
- provider: GitHub
tag: v$(GitVersion_NuGetVersionV2)
release: nanoFramework Windows.Devices.Gpio Library v$(GitVersion_NuGetVersionV2)
description: 'Check the [changelog](https://github.com/nanoframework/lib-Windows.Devices.Gpio/blob/$(appveyor_repo_branch)/CHANGELOG.md)\n\n## Install from NuGet\n\nThe following NuGet packages are available for download from this release\n\n:package: [.NET](https://www.nuget.org/packages/nanoFramework.Windows.Devices.Gpio/$(GitVersion_NuGetVersionV2)) v$(GitVersion_NuGetVersionV2)'
tag: v$(MyNuGetVersion)
release: nanoFramework Windows.Devices.Gpio Library v$(MyNuGetVersion)
description: 'Check the [changelog](https://github.com/nanoframework/lib-Windows.Devices.Gpio/blob/$(appveyor_repo_branch)/CHANGELOG.md)\n\n## Install from NuGet\n\nThe following NuGet packages are available for download from this release\n\n:package: [.NET](https://www.nuget.org/packages/nanoFramework.Windows.Devices.Gpio/$(MyNuGetVersion)) v$(MyNuGetVersion)'
auth_token:
secure: DNixoFFE+pGlwyhj7McfZoln42vOmj0iY1iNV9zXEr3y0NpXlOIgL8k5ehzlFM1S
artifact:

Просмотреть файл

@ -1,22 +1,6 @@
# Copyright (c) 2018 The nanoFramework project contributors
# See LICENSE file in the project root for full license information.
# skip updating assembly info changes if build is a pull-request or not a tag (can't commit when repo is in a tag)
if ($env:appveyor_pull_request_number -or $env:APPVEYOR_REPO_TAG -eq "true")
{
'Skip committing assembly info changes...' | Write-Host -ForegroundColor White
}
else
{
# updated assembly info files
git add "source\Windows.Devices.Gpio\Properties\AssemblyInfo.cs"
git commit -m "Update assembly info file for v$env:GitVersion_NuGetVersionV2" -m"[version update]"
git push origin --porcelain -q > $null
'Updated assembly info...' | Write-Host -ForegroundColor White -NoNewline
'OK' | Write-Host -ForegroundColor Green
}
# update assembly info in nf-interpreter if this is tag
if ($env:APPVEYOR_REPO_TAG -eq "true")
{
@ -27,13 +11,13 @@ if ($env:APPVEYOR_REPO_TAG -eq "true")
cd nf-interpreter > $null
# new branch name
$newBranch = "$env:APPVEYOR_REPO_BRANCH-nfbot/update-version/Windows.Devices.Gpio/$env:GitVersion_NuGetVersionV2"
$newBranch = "$env:APPVEYOR_REPO_BRANCH-nfbot/update-version/Windows.Devices.Gpio/$env:MyNuGetVersion"
# create branch to perform updates
git checkout -b "$newBranch" develop -q
# replace version in assembly declaration
$newVersion = $env:GitVersion_AssemblySemFileVer -replace "\." , ", "
$newVersion = $env:NBGV_AssemblyFileVersion -replace "\." , ", "
$newVersion = "{ $newVersion }"
$versionRegex = "\{\s*\d+\,\s*\d+\,\s*\d+\,\s*\d+\s*}"
@ -56,7 +40,7 @@ if ($env:APPVEYOR_REPO_TAG -eq "true")
}
else
{
$commitMessage = "Update Windows.Devices.Gpio version to $env:GitVersion_NuGetVersionV2"
$commitMessage = "Update Windows.Devices.Gpio version to $env:MyNuGetVersion"
# commit changes
git add -A 2>&1

Просмотреть файл

@ -14,7 +14,7 @@ else
if ($env:APPVEYOR_REPO_BRANCH -eq "master" -or $env:APPVEYOR_REPO_BRANCH -match "^release*")
{
# generate change log including future version
bundle exec github_changelog_generator --token $env:GitHubToken --future-release "v$env:GitVersion_MajorMinorPatch"
bundle exec github_changelog_generator --token $env:GitHubToken --future-release "v$env:NBGV_Version"
}
else
{
@ -23,8 +23,14 @@ else
bundle exec github_changelog_generator --token $env:GitHubToken
}
# updated changelog and the updated assembly info files
git add CHANGELOG.md
git commit -m "Update CHANGELOG for v$env:GitVersion_NuGetVersionV2"
git push origin --porcelain -q > $null
# updated changelog, if there are any differences
$logDif = git diff CHANGELOG.md
if($logDif -ne $null)
{
git add CHANGELOG.md
git commit -m "Update CHANGELOG for v$env:MyNuGetVersion"
# need to wrap the git command bellow so it doesn't throw an error because of redirecting the output to stderr
git push origin --porcelain | Write-Host
}
}

Просмотреть файл

@ -1,74 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug|AnyCPU">
<Configuration>Debug</Configuration>
<Platform>AnyCPU</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|AnyCPU">
<Configuration>Release</Configuration>
<Platform>AnyCPU</Platform>
</ProjectConfiguration>
</ItemGroup>
<PropertyGroup>
<GitVersion_NuGetVersionV2 Condition=" '$(GitVersion_NuGetVersionV2)' == '' ">1.0.0-preview001</GitVersion_NuGetVersionV2>
</PropertyGroup>
<ItemGroup>
<Folder Include="content\" />
</ItemGroup>
<ItemGroup>
<Content Include="..\Windows.Devices.Gpio\bin\$(Configuration)\Stubs\*.*">
<Link>content\Stubs\%(RecursiveDir)%(Filename)%(Extension)</Link>
</Content>
<Content Include="..\Windows.Devices.Gpio\bin\$(Configuration)\*.txt">
<Link>content\txt\%(RecursiveDir)%(Filename)%(Extension)</Link>
</Content>
<Content Include="..\Windows.Devices.Gpio\bin\$(Configuration)\*.dump">
<Link>content\dump\%(RecursiveDir)%(Filename)%(Extension)</Link>
</Content>
<Content Include="..\Windows.Devices.Gpio\bin\$(Configuration)\*.strings">
<Link>content\dump\%(RecursiveDir)%(Filename)%(Extension)</Link>
</Content>
<Content Include="..\Windows.Devices.Gpio\bin\$(Configuration)\*.resources">
<Link>content\resources\%(RecursiveDir)%(Filename)%(Extension)</Link>
</Content>
<Content Include="..\Windows.Devices.Gpio\bin\$(Configuration)\*.il">
<Link>content\disasm\%(RecursiveDir)%(Filename)%(Extension)</Link>
</Content>
</ItemGroup>
<ItemGroup>
<Dependency Include="nanoFramework.CoreLibrary">
<Version>[1.0.4]</Version>
</Dependency>
<Dependency Include="nanoFramework.Runtime.Events">
<Version>[1.0.0]</Version>
</Dependency>
</ItemGroup>
<PropertyGroup Label="Globals">
<ProjectGuid>8FD36AD6-387C-48F0-A695-52D9149216FB</ProjectGuid>
</PropertyGroup>
<PropertyGroup>
<NuProjPath>..\packages\NuProj.0.20.4-beta\tools\</NuProjPath>
</PropertyGroup>
<Import Project="$(NuProjPath)\NuProj.props" Condition="Exists('$(NuProjPath)\NuProj.props')" />
<PropertyGroup Label="Configuration">
<Id>nanoFramework.Windows.Devices.Gpio.DELIVERABLES</Id>
<Version>$(GitVersion_NuGetVersionV2)</Version>
<Title>nanoFramework.Windows.Devices.Gpio.DELIVERABLES</Title>
<Authors>nanoFramework project contributors</Authors>
<Owners>nanoFramework project contributors</Owners>
<Summary>nanoFramework.Windows.Devices.Gpio.DELIVERABLES is not meant for development.</Summary>
<Description>** DON'T REFERENCE THIS PACKAGE ** Not meant for development. This package includes the deliverable artifacts of the Windows.Devices.Gpio assembly for nanoFramework. These are for testing purposes and for updating the native code base of the core library.</Description>
<ReleaseNotes>
</ReleaseNotes>
<ProjectUrl>https://github.com/nanoframework/lib-Windows.Devices.Gpio</ProjectUrl>
<LicenseUrl>
</LicenseUrl>
<Copyright>Copyright (c) 2017 The nanoFramework project contributors</Copyright>
<Tags>
</Tags>
<IconUrl>https://secure.gravatar.com/avatar/97d0e092247f0716db6d4b47b7d1d1ad</IconUrl>
<GenerateSymbolPackage>false</GenerateSymbolPackage>
</PropertyGroup>
<Import Project="$(NuProjPath)\NuProj.targets" />
</Project>

Просмотреть файл

@ -1,70 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug|AnyCPU">
<Configuration>Debug</Configuration>
<Platform>AnyCPU</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|AnyCPU">
<Configuration>Release</Configuration>
<Platform>AnyCPU</Platform>
</ProjectConfiguration>
</ItemGroup>
<PropertyGroup>
<GitVersion_NuGetVersionV2 Condition=" '$(GitVersion_NuGetVersionV2)' == '' ">1.0.0-preview001</GitVersion_NuGetVersionV2>
</PropertyGroup>
<ItemGroup>
<Content Include="..\Windows.Devices.Gpio\bin\$(Configuration)\Windows.Devices.Gpio.dll">
<Link>lib\Windows.Devices.Gpio.dll</Link>
</Content>
<Content Include="..\Windows.Devices.Gpio\bin\$(Configuration)\Windows.Devices.Gpio.pdb">
<Link>lib\Windows.Devices.Gpio.pdb</Link>
</Content>
<Content Include="..\Windows.Devices.Gpio\bin\$(Configuration)\Windows.Devices.Gpio.pdbx">
<Link>lib\Windows.Devices.Gpio.pdbx</Link>
</Content>
<Content Include="..\Windows.Devices.Gpio\bin\$(Configuration)\Windows.Devices.Gpio.pe">
<Link>lib\Windows.Devices.Gpio.pe</Link>
</Content>
<Content Include="..\Windows.Devices.Gpio\bin\$(Configuration)\Windows.Devices.Gpio.xml">
<Link>lib\Windows.Devices.Gpio.xml</Link>
</Content>
</ItemGroup>
<ItemGroup>
<Folder Include="lib\" />
</ItemGroup>
<ItemGroup>
<Dependency Include="nanoFramework.CoreLibrary">
<Version>[1.0.4]</Version>
</Dependency>
<Dependency Include="nanoFramework.Runtime.Events">
<Version>[1.0.0]</Version>
</Dependency>
</ItemGroup>
<PropertyGroup Label="Globals">
<ProjectGuid>92DAD869-250B-4DFB-A340-CA3B15D05D9F</ProjectGuid>
</PropertyGroup>
<PropertyGroup>
<NuProjPath>..\packages\NuProj.0.20.4-beta\tools\</NuProjPath>
</PropertyGroup>
<Import Project="$(NuProjPath)\NuProj.props" Condition="Exists('$(NuProjPath)\NuProj.props')" />
<PropertyGroup Label="Configuration">
<Id>nanoFramework.Windows.Devices.Gpio</Id>
<Version>$(GitVersion_NuGetVersionV2)</Version>
<Title>nanoFramework.Windows.Devices.Gpio</Title>
<Authors>nanoFramework project contributors</Authors>
<Owners>nanoFramework project contributors</Owners>
<Summary>Windows.Devices.Gpio assembly for nanoFramework C# projects</Summary>
<Description>This package includes the Windows.Devices.Gpio assembly for nanoFramework C# projects</Description>
<ReleaseNotes>
</ReleaseNotes>
<ProjectUrl>https://github.com/nanoframework/lib-Windows.Devices.Gpio</ProjectUrl>
<LicenseUrl>
</LicenseUrl>
<Copyright>Copyright (c) 2017 The nanoFramework project contributors</Copyright>
<Tags>nanoFramework C# csharp netmf netnf Windows.Devices.Gpio</Tags>
<IconUrl>https://secure.gravatar.com/avatar/97d0e092247f0716db6d4b47b7d1d1ad</IconUrl>
<GenerateSymbolPackage>false</GenerateSymbolPackage>
</PropertyGroup>
<Import Project="$(NuProjPath)\NuProj.targets" />
</Project>

Просмотреть файл

@ -1,3 +0,0 @@
There is packaging tool for Visual Studio 2017 that must be installed before you should open the solution.
Please visit the [NuGetizer-3000 repository](https://github.com/NuGet/NuGet.Build.Packaging) and follow the instructions.

Просмотреть файл

@ -14,17 +14,3 @@ using System.Runtime.InteropServices;
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]
// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.1.0")]
[assembly: AssemblyVersion("1.0.1.0")]
[assembly: AssemblyFileVersion("1.0.1.0")]
[assembly: AssemblyInformationalVersion("1.0.1-preview008")]

Просмотреть файл

@ -2,4 +2,4 @@
1. After updating the Nuget packages, the project file (nfproj extension) has to be manually edited too in order to update the path for the new package for all <NFMDP_PE_LoadHints> tags.
2. The nuproj files (in nanoFramework.Windows.Devices.Gpio.Nuget.sln) have to be manually updated for the dependency versions to match the referenced packages.
2. The nuspec files have to be manually updated for the dependency versions to match the referenced packages.

Просмотреть файл

@ -87,6 +87,7 @@
</Reference>
</ItemGroup>
<Import Project="$(NanoFrameworkProjectSystemPath)NFProjectSystem.CSharp.targets" Condition="Exists('$(NanoFrameworkProjectSystemPath)NFProjectSystem.CSharp.targets')" />
<Import Project="..\packages\Nerdbank.GitVersioning.2.2.13\build\Nerdbank.GitVersioning.targets" />
<ProjectExtensions>
<ProjectCapabilities>
<ProjectConfigurationsDeclaredAsItems />

Просмотреть файл

@ -2,6 +2,5 @@
<packages>
<package id="nanoFramework.CoreLibrary" version="1.0.4" targetFramework="netnanoframework10" />
<package id="nanoFramework.Runtime.Events" version="1.0.0" targetFramework="netnanoframework10" />
<package id="NuProj" version="0.20.4-beta" developmentDependency="true" />
<package id="NuProj.Common" version="0.20.4-beta" developmentDependency="true" />
<package id="Nerdbank.GitVersioning" version="2.2.13" developmentDependency="true" />
</packages>

Просмотреть файл

@ -0,0 +1,30 @@
<?xml version="1.0" encoding="utf-8"?>
<package xmlns="http://schemas.microsoft.com/packaging/2012/06/nuspec.xsd">
<metadata>
<id>nanoFramework.Windows.Devices.Gpio.DELIVERABLES</id>
<version>$version$</version>
<title>Windows.Devices.Gpio.DELIVERABLES</title>
<authors>nanoFramework project contributors</authors>
<owners>nanoFramework project contributors</owners>
<requireLicenseAcceptance>false</requireLicenseAcceptance>
<releaseNotes></releaseNotes>
<developmentDependency>false</developmentDependency>
<projectUrl>https://github.com/nanoframework</projectUrl>
<iconUrl>https://secure.gravatar.com/avatar/97d0e092247f0716db6d4b47b7d1d1ad</iconUrl>
<copyright>Copyright (c) 2018 The nanoFramework project contributors</copyright>
<description>** DON'T REFERENCE THIS PACKAGE ** Not meant for development. This package includes the deliverable artifacts of the Windows.Devices.Gpio assembly for nanoFramework. These are for testing purposes and for updating the native code base of the library.</description>
<summary>Windows.Devices.Gpio.DELIVERABLES is not meant for development.</summary>
<tags></tags>
<dependencies>
<dependency id="nanoFramework.CoreLibrary" version="[1.0.5-preview024]" />
</dependencies>
</metadata>
<files>
<file src="Windows.Devices.Gpio\bin\Release\Stubs\*.*" target="content\Stubs\" />
<file src="Windows.Devices.Gpio\obj\Release\*.txt" target="content\txt\" />
<file src="Windows.Devices.Gpio\obj\Release\*.dump" target="content\dump\" />
<file src="Windows.Devices.Gpio\obj\Release\*.strings" target="content\dump\" />
<file src="Windows.Devices.Gpio\obj\Release\*.resources" target="content\resources\" />
<file src="Windows.Devices.Gpio\obj\Release\*.il" target="content\disasm\" />
</files>
</package>

Просмотреть файл

@ -0,0 +1,29 @@
<?xml version="1.0" encoding="utf-8"?>
<package xmlns="http://schemas.microsoft.com/packaging/2012/06/nuspec.xsd">
<metadata>
<id>nanoFramework.Windows.Devices.Gpio</id>
<version>$version$</version>
<title>nanoFramework.Windows.Devices.Gpio</title>
<authors>nanoFramework project contributors</authors>
<owners>nanoFramework project contributors</owners>
<requireLicenseAcceptance>false</requireLicenseAcceptance>
<releaseNotes></releaseNotes>
<developmentDependency>false</developmentDependency>
<projectUrl>https://github.com/nanoframework</projectUrl>
<iconUrl>https://secure.gravatar.com/avatar/97d0e092247f0716db6d4b47b7d1d1ad</iconUrl>
<copyright>Copyright (c) 2018 The nanoFramework project contributors</copyright>
<description>This package includes the Windows.Devices.Gpio assembly for nanoFramework C# projects.</description>
<summary>Windows.Devices.Gpio assembly for nanoFramework C# projects</summary>
<tags>nanoFramework C# csharp netmf netnf Windows.Devices.Gpio</tags>
<dependencies>
<dependency id="nanoFramework.CoreLibrary" version="[1.0.5-preview024]" />
</dependencies>
</metadata>
<files>
<file src="Windows.Devices.Gpio\bin\Release\Windows.Devices.Gpio.dll" target="lib\Windows.Devices.Gpio.dll" />
<file src="Windows.Devices.Gpio\bin\Release\Windows.Devices.Gpio.pdb" target="lib\Windows.Devices.Gpio.pdb" />
<file src="Windows.Devices.Gpio\bin\Release\Windows.Devices.Gpio.pdbx" target="lib\Windows.Devices.Gpio.pdbx" />
<file src="Windows.Devices.Gpio\bin\Release\Windows.Devices.Gpio.pe" target="lib\Windows.Devices.Gpio.pe" />
<file src="Windows.Devices.Gpio\bin\Release\Windows.Devices.Gpio.xml" target="lib\Windows.Devices.Gpio.xml" />
</files>
</package>

Просмотреть файл

@ -5,16 +5,6 @@ VisualStudioVersion = 15.0.27130.2010
MinimumVisualStudioVersion = 10.0.40219.1
Project("{11A8DD76-328B-46DF-9F39-F559912D0360}") = "Windows.Devices.Gpio", "Windows.Devices.Gpio\Windows.Devices.Gpio.nfproj", "{2FC2FDB5-DCEC-4B99-B9AD-5E45CED385E5}"
EndProject
Project("{FF286327-C783-4F7A-AB73-9BCBAD0D4460}") = "Nuget.Windows.Devices.Gpio", "Nuget.Windows.Devices.Gpio\Nuget.Windows.Devices.Gpio.nuproj", "{92DAD869-250B-4DFB-A340-CA3B15D05D9F}"
ProjectSection(ProjectDependencies) = postProject
{2FC2FDB5-DCEC-4B99-B9AD-5E45CED385E5} = {2FC2FDB5-DCEC-4B99-B9AD-5E45CED385E5}
EndProjectSection
EndProject
Project("{FF286327-C783-4F7A-AB73-9BCBAD0D4460}") = "Nuget.Windows.Devices.Gpio.DELIVERABLES", "Nuget.Windows.Devices.Gpio.DELIVERABLES\Nuget.Windows.Devices.Gpio.DELIVERABLES.nuproj", "{8FD36AD6-387C-48F0-A695-52D9149216FB}"
ProjectSection(ProjectDependencies) = postProject
{2FC2FDB5-DCEC-4B99-B9AD-5E45CED385E5} = {2FC2FDB5-DCEC-4B99-B9AD-5E45CED385E5}
EndProjectSection
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
@ -25,14 +15,6 @@ Global
{2FC2FDB5-DCEC-4B99-B9AD-5E45CED385E5}.Debug|Any CPU.Build.0 = Debug|Any CPU
{2FC2FDB5-DCEC-4B99-B9AD-5E45CED385E5}.Release|Any CPU.ActiveCfg = Release|Any CPU
{2FC2FDB5-DCEC-4B99-B9AD-5E45CED385E5}.Release|Any CPU.Build.0 = Release|Any CPU
{92DAD869-250B-4DFB-A340-CA3B15D05D9F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{92DAD869-250B-4DFB-A340-CA3B15D05D9F}.Debug|Any CPU.Build.0 = Debug|Any CPU
{92DAD869-250B-4DFB-A340-CA3B15D05D9F}.Release|Any CPU.ActiveCfg = Release|Any CPU
{92DAD869-250B-4DFB-A340-CA3B15D05D9F}.Release|Any CPU.Build.0 = Release|Any CPU
{8FD36AD6-387C-48F0-A695-52D9149216FB}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{8FD36AD6-387C-48F0-A695-52D9149216FB}.Debug|Any CPU.Build.0 = Debug|Any CPU
{8FD36AD6-387C-48F0-A695-52D9149216FB}.Release|Any CPU.ActiveCfg = Release|Any CPU
{8FD36AD6-387C-48F0-A695-52D9149216FB}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE

26
source/version.json Normal file
Просмотреть файл

@ -0,0 +1,26 @@
{
"$schema": "https://raw.githubusercontent.com/AArnott/Nerdbank.GitVersioning/master/src/NerdBank.GitVersioning/version.schema.json",
"version": "1.0.2-preview.{height}",
"assemblyVersion": {
"precision": "revision"
},
"semVer1NumericIdentifierPadding": 3,
"nugetPackageVersion": {
"semVer": 1
},
"publicReleaseRefSpec": [
"^refs/heads/master$",
"^refs/heads/v\\d+(?:\\.\\d+)?$"
],
"cloudBuild": {
"setVersionVariables": true,
"setAllVariables": true,
"buildNumber": {
"enabled": true,
"includeCommitId": {
"when": "nonPublicReleaseOnly",
"where": "buildMetadata"
}
}
}
}

Просмотреть файл

@ -57,8 +57,8 @@ else
foreach ($node in $nodes)
{
# filter out NuProj packages
if($node.id -notlike "NuProj*")
# filter out Nerdbank.GitVersioning package
if($node.id -notlike "Nerdbank.GitVersioning*")
{
if($packageList)
{
@ -90,7 +90,7 @@ else
# update all packages
foreach ($package in $packageList)
{
# get package name and origin version
# get package name and target version
$packageName = $package[0]
$packageOriginVersion = $package[1]
@ -105,7 +105,7 @@ else
# allow prerelease for all others
$updatePackage = nuget update $solutionFile[0].FullName -Source https://www.myget.org/F/nanoframework-dev/api/v3/index.json -Source https://api.nuget.org/v3/index.json -PreRelease
}
# need to get target version
# load packages.config as XML doc
[xml]$packagesDoc = Get-Content $packagesConfig
@ -129,32 +129,36 @@ else
attrib $projectPath -r
$filecontent -replace "($packageName.$packageOriginVersion)", "$packageName.$packageTargetVersion" | Out-File $projectPath -Encoding utf8
# update nuproj files, if any
$nuprojFiles = (Get-ChildItem -Path ".\" -Include "*.nuproj" -Recurse)
# update nuspec files, if any
$nuspecFiles = (Get-ChildItem -Path ".\" -Include "*.nuspec" -Recurse)
foreach ($nuproj in $nuprojFiles)
foreach ($nuspec in $nuspecFiles)
{
[xml]$nuprojDoc = Get-Content $nuproj
[xml]$nuspecDoc = Get-Content $nuspec
#$nuprojDoc.Project.ItemGroup
$nodes = $nuprojDoc.SelectNodes("*").SelectNodes("*")
$nodes = $nuspecDoc.SelectNodes("*").SelectNodes("*")
foreach ($node in $nodes)
{
if($node.Name -eq "ItemGroup")
if($node.Name -eq "metadata")
{
foreach ($itemGroup in $node.ChildNodes)
{
if($itemGroup.Name -eq "Dependency" -and $itemGroup.Attributes["Include"].value -eq $packageName)
foreach ($metadataItem in $node.ChildNodes)
{
if($metadataItem.Name -eq "dependencies")
{
$itemGroup.ChildNodes[0].innertext = "[$packageTargetVersion]"
foreach ($dependency in $metadataItem.ChildNodes)
{
if($dependency.Attributes["id"].value -eq $packageName)
{
$dependency.Attributes["version"].value = "[$packageTargetVersion]"
}
}
}
}
}
}
$nuprojDoc.Save($nuproj[0].FullName)
$nuspecDoc.Save($nuspec[0].FullName)
}
# update branch name