Created
January 4, 2016 19:31
-
-
Save dmsimard/cc762cd3f016270c83e7 to your computer and use it in GitHub Desktop.
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
key: 6bf597e0-8a98-478b-9a88-e9e389fdfd38 |
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
# Use regex_replace to return only the first 13 characters | |
# Equivalent to a command that'd be like: | |
# - echo $key |sed -e 's/^\(.\{13\}\).*/\1/' | |
# - echo $key |cut -c 1-13 | |
- debug: | |
msg: "{{ key | regex_replace('^(.{13}).*', '\\1' }}" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment