Can I get the type of build?

cameron.taggart's Avatar

cameron.taggart

17 Mar, 2015 04:23 AM

I would like to do something different depending on the type of build. It looks like it is possible to see if it is scheduled build or not using the environment variable:
APPVEYOR_SCHEDULED_BUILD - True if the build runs by scheduler

However, I don't know if a build was created by a commit or via the NEW BUILD or RE-BUILD COMMIT buttons. vs just a normal commit. Is there any way to differentiate?

  1. Support Staff 1 Posted by Feodor Fitsner on 17 Mar, 2015 04:34 AM

    Feodor Fitsner's Avatar

    Nope at the moment, but I think this could be easily added. Why would you need that - could you please elaborate?

  2. 2 Posted by cameron.taggart on 17 Mar, 2015 04:43 AM

    cameron.taggart's Avatar

    I'm going to run FAKE targets based on #hashtags in the commit message. I only want that to be picked up when the build is triggered by a normal push to the repository, not when it is a schedule build or a new build or a re-build commit.

    https://github.com/ctaggart/SourceLink/issues/65

  3. Support Staff 3 Posted by Feodor Fitsner on 17 Mar, 2015 06:13 AM

    Feodor Fitsner's Avatar

    How about adding two new variables:

    • APPVEYOR_FORCED_BUILD (True/False) - builds started by "New build" button or from the same API.
    • APPVEYOR_RE_BUILD (True/False) - build started by "Re-build commit/PR" button of from the same API.
  4. 4 Posted by cameron.taggart on 17 Mar, 2015 06:16 AM

    cameron.taggart's Avatar

    That would work for me.

  5. Support Staff 5 Posted by Feodor Fitsner on 23 Mar, 2015 10:36 AM

    Feodor Fitsner's Avatar

    Just to let you know that the update with these two vars was deployed.

  6. Ilya Finkelshteyn closed this discussion on 25 Aug, 2018 01:54 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

 

26 Sep, 2024 03:49 PM
26 Sep, 2024 09:02 AM
25 Sep, 2024 07:07 PM
24 Sep, 2024 08:39 PM
24 Sep, 2024 06:47 AM
20 Sep, 2024 05:50 PM