/cleanupdecorator-bash.yml Secret
Last active
April 16, 2023 18:20
Star
You must be signed in to star a gist
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
steps: | |
- task: Bash@3 | |
displayName: Clean workspace | |
continueOnError: true | |
inputs: | |
targetType: 'inline' | |
script: | | |
shopt -s dotglob | |
rm -rf $(Pipeline.Workspace)/s/* | |
rm -rf $(Pipeline.Workspace)/a/* | |
rm -rf $(Pipeline.Workspace)/b/* | |
rm -rf $(Pipeline.Workspace)/testresults/* | |
find $(Pipeline.Workspace) -mindepth 1 -maxdepth 1 ! \( -name s -o -name a -o -name b - | |
o -name testresults \) -exec rm -rf {} + | |
shopt -u dotglob | |
exit 0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment