mirror of
https://github.com/tribufu/ServerManagers
synced 2026-05-06 15:17:34 +00:00
pipeline file changes
This commit is contained in:
parent
7881199ec1
commit
d2eeb557ca
2 changed files with 70 additions and 15 deletions
|
|
@ -24,7 +24,7 @@ stages:
|
|||
|
||||
steps:
|
||||
- task: PowerShell@2
|
||||
displayName: Clean-up Agent Folders
|
||||
displayName: Pre Clean-up Agent Folders
|
||||
env:
|
||||
BUILD_ARTIFACTSTAGINGDIRECTORY: $(Build.ArtifactStagingDirectory)
|
||||
BUILD_BINARIESDIRECTORY: $(Build.BinariesDirectory)
|
||||
|
|
@ -254,7 +254,7 @@ stages:
|
|||
ArtifactName: '${{parameters.PublishFolder}}'
|
||||
|
||||
- task: PowerShell@2
|
||||
displayName: Clean-up Agent Folders
|
||||
displayName: Post Clean-up Agent Folders
|
||||
condition: always()
|
||||
env:
|
||||
BUILD_ARTIFACTSTAGINGDIRECTORY: $(Build.ArtifactStagingDirectory)
|
||||
|
|
|
|||
|
|
@ -54,18 +54,45 @@ stages:
|
|||
runOnce:
|
||||
deploy:
|
||||
steps:
|
||||
- task: PowerShell@2
|
||||
displayName: Pre Clean-up Agent Folders
|
||||
env:
|
||||
BUILD_ARTIFACTSTAGINGDIRECTORY: $(Build.ArtifactStagingDirectory)
|
||||
BUILD_BINARIESDIRECTORY: $(Build.BinariesDirectory)
|
||||
BUILD_SOURCESDIRECTORY: $(Build.SourcesDirectory)
|
||||
BUILD_PUBLISHDIRECTORY: "$(Build.BuildDirectory)/${{parameters.PublishFolder}}"
|
||||
inputs:
|
||||
targetType: inline
|
||||
script: |
|
||||
if (Test-Path $env:BUILD_ARTIFACTSTAGINGDIRECTORY) {
|
||||
Remove-Item -Path "$env:BUILD_ARTIFACTSTAGINGDIRECTORY\*" -Filter '*.*' -Recurse -Force -ErrorAction SilentlyContinue
|
||||
}
|
||||
|
||||
if (Test-Path $env:BUILD_BINARIESDIRECTORY) {
|
||||
Remove-Item -Path "$env:BUILD_BINARIESDIRECTORY\*" -Filter '*.*' -Recurse -Force -ErrorAction SilentlyContinue
|
||||
}
|
||||
|
||||
if (Test-Path $env:BUILD_SOURCESDIRECTORY) {
|
||||
Remove-Item -Path "$env:BUILD_SOURCESDIRECTORY\*" -Filter '*.*' -Recurse -Force -ErrorAction SilentlyContinue
|
||||
}
|
||||
|
||||
if (Test-Path $env:BUILD_PUBLISHDIRECTORY) {
|
||||
Remove-Item -Path "$env:BUILD_PUBLISHDIRECTORY" -Filter '*.*' -Recurse -Force -ErrorAction SilentlyContinue
|
||||
}
|
||||
pwsh: true
|
||||
|
||||
- checkout: GitHubRepo
|
||||
|
||||
- task: PowerShell@2
|
||||
displayName: Output Environment Variables
|
||||
condition: contains(variables['system.debug'], 'true')
|
||||
#condition: contains(variables['system.debug'], 'true')
|
||||
inputs:
|
||||
targetType: inline
|
||||
script: '(gci env:*).GetEnumerator() | Sort-Object Name | Out-String'
|
||||
pwsh: true
|
||||
|
||||
- task: PowerShell@2
|
||||
displayName: Clean-up Agent Folders
|
||||
displayName: Post Clean-up Agent Folders
|
||||
condition: always()
|
||||
env:
|
||||
BUILD_ARTIFACTSTAGINGDIRECTORY: $(Build.ArtifactStagingDirectory)
|
||||
|
|
@ -108,18 +135,46 @@ stages:
|
|||
runOnce:
|
||||
deploy:
|
||||
steps:
|
||||
- checkout: GitHubRepo
|
||||
|
||||
- task: PowerShell@2
|
||||
displayName: Output Environment Variables
|
||||
condition: contains(variables['system.debug'], 'true')
|
||||
inputs:
|
||||
targetType: inline
|
||||
script: '(gci env:*).GetEnumerator() | Sort-Object Name | Out-String'
|
||||
pwsh: true
|
||||
|
||||
- task: PowerShell@2
|
||||
displayName: Clean-up Agent Folders
|
||||
displayName: Pre Clean-up Agent Folders
|
||||
condition: always()
|
||||
env:
|
||||
BUILD_ARTIFACTSTAGINGDIRECTORY: $(Build.ArtifactStagingDirectory)
|
||||
BUILD_BINARIESDIRECTORY: $(Build.BinariesDirectory)
|
||||
BUILD_SOURCESDIRECTORY: $(Build.SourcesDirectory)
|
||||
BUILD_PUBLISHDIRECTORY: "$(Build.BuildDirectory)/$(PublishFolder)"
|
||||
inputs:
|
||||
targetType: inline
|
||||
script: |
|
||||
if (Test-Path $env:BUILD_ARTIFACTSTAGINGDIRECTORY) {
|
||||
Remove-Item -Path "$env:BUILD_ARTIFACTSTAGINGDIRECTORY\*" -Filter '*.*' -Recurse -Force -ErrorAction SilentlyContinue
|
||||
}
|
||||
|
||||
if (Test-Path $env:BUILD_BINARIESDIRECTORY) {
|
||||
Remove-Item -Path "$env:BUILD_BINARIESDIRECTORY\*" -Filter '*.*' -Recurse -Force -ErrorAction SilentlyContinue
|
||||
}
|
||||
|
||||
if (Test-Path $env:BUILD_SOURCESDIRECTORY) {
|
||||
Remove-Item -Path "$env:BUILD_SOURCESDIRECTORY\*" -Filter '*.*' -Recurse -Force -ErrorAction SilentlyContinue
|
||||
}
|
||||
|
||||
if (Test-Path $env:BUILD_PUBLISHDIRECTORY) {
|
||||
Remove-Item -Path "$env:BUILD_PUBLISHDIRECTORY" -Filter '*.*' -Recurse -Force -ErrorAction SilentlyContinue
|
||||
}
|
||||
pwsh: true
|
||||
|
||||
- checkout: GitHubRepo
|
||||
|
||||
- task: PowerShell@2
|
||||
displayName: Output Environment Variables
|
||||
#condition: contains(variables['system.debug'], 'true')
|
||||
inputs:
|
||||
targetType: inline
|
||||
script: '(gci env:*).GetEnumerator() | Sort-Object Name | Out-String'
|
||||
pwsh: true
|
||||
|
||||
- task: PowerShell@2
|
||||
displayName: Post Clean-up Agent Folders
|
||||
condition: always()
|
||||
env:
|
||||
BUILD_ARTIFACTSTAGINGDIRECTORY: $(Build.ArtifactStagingDirectory)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue