'How to get resource build version in pipeline?

resources:
  builds:
  - build: Spaceworkz
    type: Jenkins
    connection: MyJenkinsServer 
    source: SpaceworkzProj   # name of the jenkins source project
    trigger: true

Then, I use downloadBuild step.

How can I later in the pipeline get the version number of this build? It will be "latest" but I need the version number.

I can't see anything in doc.



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source