Commit a1ea6121 authored by Vinicius Jarina's avatar Vinicius Jarina
Browse files

Added UWP support.

parent 1a39e4db
param ([string] $PackageId, [string] $NuSpecFile) param ([string] $PackageId)
. .\devops\BuildFunctions.ps1 . .\devops\BuildFunctions.ps1
$nextVersion = Get-Next-Version-String $PackageId $nextVersion = Get-Next-Version-String $PackageId
$NuSpecFile = $PackageId + '.nuspec'
Update-NuSpec-Version $NuSpecFile $nextVersion Update-NuSpec-Version $NuSpecFile $nextVersion
gitversion /updateassemblyinfo gitversion /updateassemblyinfo
...@@ -6,23 +6,6 @@ if (-Not (Test-Should-Deploy)) { ...@@ -6,23 +6,6 @@ if (-Not (Test-Should-Deploy)) {
return return
} }
$nextVersion = Get-Next-Version-String $PackageId $nupkgFile = $PackageId + '.nupkg'
if (Test-Package-Already-Published $PackageId $nextVersion) { & nuget push $nupkgFile -Source https://www.nuget.org/api/v2/package
return
}
$versionToUnlist = ""
if (-Not (Test-Version-Stable-Release $nextVersion)) {
$publishedVersion = Get-Published-PreRelase-Package $PackageId
if (-Not (Test-Version-Stable-Release $publishedVersion)) {
$versionToUnlist = $publishedVersion
}
}
& nuget push *.nupkg -Source https://www.nuget.org/api/v2/package
# Unlist previous Pre-Release packages.
if ($versionToUnlist -ne "") {
& $nuget delete $versionToUnlist -Source https://www.nuget.org/api/v2/package
}
\ No newline at end of file
...@@ -37,7 +37,8 @@ jobs: ...@@ -37,7 +37,8 @@ jobs:
inputs: inputs:
targetType: filePath targetType: filePath
filePath: ./devops/PreBuild.ps1 filePath: ./devops/PreBuild.ps1
arguments: 'NLua NLua.nuspec' arguments: 'NLua'
pwsh: true
- task: MSBuild@1 - task: MSBuild@1
displayName: 'Build solution NLua.sln' displayName: 'Build solution NLua.sln'
...@@ -51,7 +52,7 @@ jobs: ...@@ -51,7 +52,7 @@ jobs:
solution: NLua.Mac.sln solution: NLua.Mac.sln
configuration: Release configuration: Release
- script: 'mono packages/NUnit.ConsoleRunner.3.10.0/tools/nunit3-console.exe ./tests/build/net45/bin/Release/NLuaTest.dll --result=TEST-Result-Mac.xml' - script: 'mono packages/NUnit.ConsoleRunner.3.11.1/tools/nunit3-console.exe ./tests/build/net45/bin/Release/NLuaTest.dll --result=TEST-Result-Mac.xml'
displayName: 'Run OSX tests' displayName: 'Run OSX tests'
- task: PublishTestResults@2 - task: PublishTestResults@2
...@@ -156,6 +157,11 @@ jobs: ...@@ -156,6 +157,11 @@ jobs:
inputs: inputs:
restoreSolution: NLua.sln restoreSolution: NLua.sln
- task: NuGetCommand@2
displayName: 'NuGet restore NLua.UWP'
inputs:
restoreSolution: NLua.UWP.sln
- task: NuGetCommand@2 - task: NuGetCommand@2
displayName: 'NuGet restore' displayName: 'NuGet restore'
inputs: inputs:
...@@ -165,7 +171,7 @@ jobs: ...@@ -165,7 +171,7 @@ jobs:
displayName: 'PreBuild Script' displayName: 'PreBuild Script'
inputs: inputs:
filePath: './devops/PreBuild.ps1' filePath: './devops/PreBuild.ps1'
arguments: 'NLua NLua.nuspec' arguments: 'NLua'
errorActionPreference: 'silentlyContinue' errorActionPreference: 'silentlyContinue'
pwsh: true pwsh: true
...@@ -175,6 +181,13 @@ jobs: ...@@ -175,6 +181,13 @@ jobs:
solution: 'NLua.sln' solution: 'NLua.sln'
configuration: Release configuration: Release
- task: MSBuild@1
displayName: 'Build UWP'
inputs:
solution: 'NLua.UWP.sln'
configuration: Release
msbuildArguments: /restore
- task: MSBuild@1 - task: MSBuild@1
displayName: 'Build .NET Core' displayName: 'Build .NET Core'
inputs: inputs:
...@@ -262,7 +275,8 @@ jobs: ...@@ -262,7 +275,8 @@ jobs:
inputs: inputs:
targetType: filePath targetType: filePath
filePath: ./devops/Package.ps1 filePath: ./devops/Package.ps1
arguments: 'NLua NLua.nuspec' arguments: 'NLua'
pwsh: true
- script: 'rename *.nupkg NLua.nupkg' - script: 'rename *.nupkg NLua.nupkg'
displayName: 'Rename Nuget Package' displayName: 'Rename Nuget Package'
...@@ -279,6 +293,7 @@ jobs: ...@@ -279,6 +293,7 @@ jobs:
targetType: filePath targetType: filePath
filePath: ./devops/Publish.ps1 filePath: ./devops/Publish.ps1
arguments: NLua arguments: NLua
pwsh: true
- template: send-telegram.yml@templates - template: send-telegram.yml@templates
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment