Setting the version (via the API) doesn't update the environment variable

James Murphy's Avatar

James Murphy

05 Jun, 2014 08:42 AM

As part of my build process I calculate and set the version number via a post to the build agent API.

This works in terms of setting the version number shown in the history but it doesn't appear to update the environment variable meaning I have to get slightly creative to pass the value to a later step in the process (I need a playground to see how all this stuff interacts!)

  1. Support Staff 1 Posted by Feodor Fitsner on 05 Jun, 2014 05:12 PM

    Feodor Fitsner's Avatar

    Good catch, will add that to issues! Thanks.

  2. 2 Posted by James Murphy on 06 Aug, 2014 11:13 AM

    James Murphy's Avatar

    Still doesn't assuming my incantation to create an artifact is right:

    artifacts:
      - path: publish
        name: appveyor.$(APPVEYOR_VERSION_NUMBER)
    
  3. Support Staff 3 Posted by Feodor Fitsner on 06 Aug, 2014 10:51 PM

    Feodor Fitsner's Avatar

    As a workaround you can just set this variable in the same place where you call Build API, kind of:

    $env:APPVEYOR_VERSION_NUMBER = 'version'
    
  4. 4 Posted by James Murphy on 27 Nov, 2014 09:38 AM

    James Murphy's Avatar

    Yay, I see you have this working right now

  5. James Murphy closed this discussion on 27 Nov, 2014 09:38 AM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac

 

22 Aug, 2019 08:13 PM
21 Aug, 2019 11:06 PM
21 Aug, 2019 02:08 PM
21 Aug, 2019 01:37 PM
21 Aug, 2019 10:21 AM
21 Aug, 2019 05:56 AM