pr: none trigger: none name: 1.8.$(Rev:r) pool: vmImage: ubuntu-latest variables: buildConfiguration: 'Release' stages: - stage: publish jobs: - job: publish steps: - checkout: self persistCredentials: true - task: UseDotNet@2 displayName: 'Use .NET Core sdk' inputs: packageType: 'sdk' version: '6.0.x' includePreviewVersions: true - task: DotNetCoreCLI@2 inputs: command: 'pack' packagesToPack: '**/*.csproj' includesymbols: true versioningScheme: 'byEnvVar' versionEnvVar: 'Build.BuildNumber' buildProperties: 'NoWarn="0419;1573;1591";Version=$(Build.BuildNumber);ContinuousIntegrationBuild=true' - task: NuGetCommand@2 inputs: command: 'push' packagesToPush: '$(Build.ArtifactStagingDirectory)/**/*.nupkg' nuGetFeedType: 'external' publishFeedCredentials: 'nuget.org' - script: | git tag $(Build.BuildNumber) git push --tags workingDirectory: $(Build.SourcesDirectory) displayName: Git Tag - stage: notify jobs: - job: notify pool: server steps: - task: InvokeRESTAPI@1 inputs: connectionType: 'connectedServiceName' serviceConnection: 'Telegram Deploy Notice' method: 'POST' body: | { "status": "success", "complete": true, "message": "{ \"commitId\": \"$(Build.SourceVersion)\", \"buildNumber\": \"$(Build.BuildNumber)\", \"teamProjectName\": \"$(system.TeamProject)\" }" } waitForCompletion: 'false'