Force Build on Specific Tag?

Mike-EEE's Avatar

Mike-EEE

27 Nov, 2019 12:16 PM

I am attempting to force a build after an external workflow has completed.

In regards to this question:
https://help.appveyor.com/discussions/questions/44161-are-filters-ignored-on-manually-triggered-builds

It would seem filters are ignored when this API call is invoked.

However, it would seem that the `branches.only` field _is_ respected, as I have configured the build definition to use separate configurations via the `for:` keyword, and the `master` branch selection is being built, as defined here:

https://github.com/ExtendedXmlSerializer/NextRelease/blob/2cb93e001f8ddc7689461df0641fbbbf97644bdd/.build/appveyor.yml#L81-L83

However, naturally, this is not what I want. xD

This forced build is to simulate a tagged build, but there is no `tag` field in the api call. Is there a way to trigger a forced build with a specific tag?

FWIW, I am wanting to select this configuration:
https://github.com/ExtendedXmlSerializer/NextRelease/blob/2cb93e001f8ddc7689461df0641fbbbf97644bdd/.build/appveyor.yml#L43-L46

  1. 1 Posted by Mike-EEE on 27 Nov, 2019 01:24 PM

    Mike-EEE's Avatar

    Looks like setting both the branch and commitID as the tag name will check out the branch as the tag:

    ```
    $body = @{
                 accountName = $env:DEPLOY_ACCOUNT
                 projectSlug = $env:DEPLOY_SLUG
                 branch = $tagName
                 commitId = $tagName
    }
    ```

    However, the response still denotes that it is not in a tagged context:

    ```
    buildId : 29158162
    version : 9.0.11.0
    branch : 9.0.11
    ...
    isTag : False
    ```

    I am able to select the branch now. However, it would be nice to know if there is a way to fully simulate a "tagged" build when manually forcing it.

  2. Support Staff 2 Posted by Feodor Fitsner on 28 Nov, 2019 08:19 PM

    Feodor Fitsner's Avatar

    You can introduce some environment variable into new build API request, saying it's tag build.

  3. 3 Posted by Mike-EEE on 28 Nov, 2019 09:11 PM

    Mike-EEE's Avatar

    Alright. I was hoping/looking for something more official, but it sounds like there isn't... what we have will do, however, so no biggie.

  4. Mike-EEE closed this discussion on 28 Nov, 2019 09:11 PM.

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

Recent Discussions

05 Dec, 2019 09:12 PM
04 Dec, 2019 07:46 PM
04 Dec, 2019 12:01 AM
04 Dec, 2019 12:00 AM
03 Dec, 2019 11:00 PM