@@ -50,14 +50,32 @@ jobs:
50
50
command : ' build'
51
51
configuration : $(BuildConfiguration)
52
52
projects : ' src/ExchangeSharpConsole/ExchangeSharpConsole.csproj'
53
+ # - task: DotNetCoreCLI@2
54
+ # displayName: 'Tests'
55
+ # inputs:
56
+ # command: 'test'
57
+ # configuration: $(BuildConfiguration)
58
+ # projects: 'tests/*/*.csproj'
59
+ # publishTestResults: true
60
+ # testRunTitle: 'All tests'
53
61
- task : DotNetCoreCLI@2
54
- displayName : ' Tests '
62
+ displayName : ' NuGet Pack '
55
63
inputs :
56
- command : ' test'
57
- configuration : $(BuildConfiguration)
58
- projects : ' tests/*/*.csproj'
59
- publishTestResults : true
60
- testRunTitle : ' All tests'
64
+ command : pack
65
+ packagesToPack : ' **/*.csproj'
66
+ packDestination : ' $(Build.ArtifactStagingDirectory)'
67
+ versioningScheme : byPrereleaseNumber
68
+ majorVersion : ' $(Major)'
69
+ minorVersion : ' $(Minor)'
70
+ patchVersion : ' $(Patch)'
71
+ - task : NuGetAuthenticate@0
72
+ displayName : ' NuGet Authenticate'
73
+ - task : NuGetCommand@2
74
+ displayName : ' NuGet push'
75
+ inputs :
76
+ command : push
77
+ publishVstsFeed : ' PublicProject/DigitalRuby'
78
+ allowPackageConflicts : true
61
79
- job : build_tag
62
80
displayName : Build console app
63
81
timeoutInMinutes : 5
83
101
condition : eq(variables['Agent.OS'], 'Darwin')
84
102
inputs :
85
103
packageType : sdk
86
- version : 3.0.100
104
+ version : 6.x
87
105
installationPath : $(Agent.ToolsDirectory)/dotnet
88
106
- task : DotNetCoreCLI@2
89
107
displayName : " Publish console executable"
@@ -114,7 +132,7 @@ jobs:
114
132
dependsOn : build_tag
115
133
continueOnError : false
116
134
pool :
117
- vmImage : ubuntu-18.04
135
+ vmImage : ubuntu-latest
118
136
condition : or(eq(variables['Build.Reason'], 'Schedule'), startsWith(variables['Build.SourceBranch'], 'refs/tags'))
119
137
steps :
120
138
- bash : echo "##vso[task.setvariable variable=TAG;isOutput=true]$(git describe --tags --exact-match)"
0 commit comments