Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save crpietschmann/7249fa9489c00f344f712a68f87037fc to your computer and use it in GitHub Desktop.
Save crpietschmann/7249fa9489c00f344f712a68f87037fc to your computer and use it in GitHub Desktop.
Azure DevOps Variables - pass variable from on step to another
jobs:
- job: JobOne
pool:
vmImage: 'ubuntu-latest'
steps:
- bash: |
NOW=$( date '+%F_%H:%M:%S' )
echo "##vso[task.setvariable variable=currentTime]$NOW"
displayName: Get Date
- bash: |
echo $(currentTime)
displayName: Show Date
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment