mirror of
https://github.com/tribufu/ServerManagers
synced 2026-06-01 09:42:39 +00:00
Update azure-pipelines.yml for Azure Pipelines
This commit is contained in:
parent
de572ae94e
commit
9ec961ad2d
1 changed files with 62 additions and 55 deletions
|
|
@ -22,18 +22,26 @@ variables:
|
||||||
- name: PublishFolder
|
- name: PublishFolder
|
||||||
value: publish
|
value: publish
|
||||||
|
|
||||||
steps:
|
stages:
|
||||||
- task: NuGetToolInstaller@1
|
- stage: build
|
||||||
|
displayName: Build and Publish
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
- job: build
|
||||||
|
displayName: Build and Publish
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- task: NuGetToolInstaller@1
|
||||||
displayName: 'Install NuGet 4.4.1'
|
displayName: 'Install NuGet 4.4.1'
|
||||||
inputs:
|
inputs:
|
||||||
versionSpec: '4.4.1'
|
versionSpec: '4.4.1'
|
||||||
|
|
||||||
- task: NuGetCommand@2
|
- task: NuGetCommand@2
|
||||||
displayName: 'NuGet restore'
|
displayName: 'NuGet restore'
|
||||||
inputs:
|
inputs:
|
||||||
restoreSolution: '$(SolutionFile)'
|
restoreSolution: '$(SolutionFile)'
|
||||||
|
|
||||||
- task: PowerShell@2
|
- task: PowerShell@2
|
||||||
displayName: 'Apply Semantic Versioning to Assemblies'
|
displayName: 'Apply Semantic Versioning to Assemblies'
|
||||||
inputs:
|
inputs:
|
||||||
targetType: filePath
|
targetType: filePath
|
||||||
|
|
@ -41,21 +49,21 @@ steps:
|
||||||
arguments: "-applicationName $(ApplicationName) -pathToSearch '$(Build.SourcesDirectory)/src' -buildNumber $(Build.BuildNumber) -searchFilter 'AssemblyInfo.*'"
|
arguments: "-applicationName $(ApplicationName) -pathToSearch '$(Build.SourcesDirectory)/src' -buildNumber $(Build.BuildNumber) -searchFilter 'AssemblyInfo.*'"
|
||||||
pwsh: true
|
pwsh: true
|
||||||
|
|
||||||
- task: projectfileprops@1
|
- task: projectfileprops@1
|
||||||
displayName: 'Modify ApplicationVersion In Project File'
|
displayName: 'Modify ApplicationVersion In Project File'
|
||||||
inputs:
|
inputs:
|
||||||
path: '$(ProjectFile)'
|
path: '$(ProjectFile)'
|
||||||
fieldOptions: ApplicationVersion
|
fieldOptions: ApplicationVersion
|
||||||
value: '$(VersionMajor).$(VersionMinor).$(VersionBuild).%2a'
|
value: '$(VersionMajor).$(VersionMinor).$(VersionBuild).%2a'
|
||||||
|
|
||||||
- task: projectfileprops@1
|
- task: projectfileprops@1
|
||||||
displayName: 'Modify ApplicationRevision In Project File'
|
displayName: 'Modify ApplicationRevision In Project File'
|
||||||
inputs:
|
inputs:
|
||||||
path: '$(ProjectFile)'
|
path: '$(ProjectFile)'
|
||||||
fieldOptions: ApplicationRevision
|
fieldOptions: ApplicationRevision
|
||||||
value: '$(VersionRevision)'
|
value: '$(VersionRevision)'
|
||||||
|
|
||||||
- task: VSBuild@1
|
- task: VSBuild@1
|
||||||
displayName: 'Build $(ApplicationName) Project'
|
displayName: 'Build $(ApplicationName) Project'
|
||||||
inputs:
|
inputs:
|
||||||
solution: '$(ProjectFile)'
|
solution: '$(ProjectFile)'
|
||||||
|
|
@ -64,7 +72,7 @@ steps:
|
||||||
configuration: '$(BuildConfiguration)'
|
configuration: '$(BuildConfiguration)'
|
||||||
clean: true
|
clean: true
|
||||||
|
|
||||||
- task: CopyFiles@2
|
- task: CopyFiles@2
|
||||||
displayName: 'Copy Artifact Files'
|
displayName: 'Copy Artifact Files'
|
||||||
inputs:
|
inputs:
|
||||||
SourceFolder: '$(Build.SourcesDirectory)'
|
SourceFolder: '$(Build.SourcesDirectory)'
|
||||||
|
|
@ -78,9 +86,8 @@ steps:
|
||||||
flattenFolders: true
|
flattenFolders: true
|
||||||
preserveTimestamp: true
|
preserveTimestamp: true
|
||||||
|
|
||||||
- task: PublishBuildArtifacts@1
|
- task: PublishBuildArtifacts@1
|
||||||
displayName: 'Publish Artifacts'
|
displayName: 'Publish Artifacts'
|
||||||
inputs:
|
inputs:
|
||||||
PathtoPublish: '$(Build.ArtifactStagingDirectory)'
|
PathtoPublish: '$(Build.ArtifactStagingDirectory)'
|
||||||
ArtifactName: '$(PublishFolder)'
|
ArtifactName: '$(PublishFolder)'
|
||||||
condition: succeededOrFailed()
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue