Meaning of "global:" in "environment:" of appveyor.yml

vitaly.krugl.numenta's Avatar


18 Mar, 2016 12:28 AM has a commented-out example that uses the section "global:" inside "environment:", but it doesn't explain the significance of having environment variables declared inside this "global:" section versus simply declaring environment variables directly inside "environment:".

For example:

  my_var1: value1

    my_var2: value2

What's the difference between my_var1 that's declared under environment and my_var2 that's declared inside global?

Many thanks,

  1. Support Staff 1 Posted by Feodor Fitsner on 18 Mar, 2016 02:52 AM

    Feodor Fitsner's Avatar

    "global:" is used together with "matrix:" and allows defining variables for all matrix permutations.


  2. 2 Posted by wtf? on 07 Nov, 2017 12:44 PM

    wtf?'s Avatar

    So variables inside `environment:` aren't visible inside matrix jobs?

  3. Support Staff 3 Posted by Ilya Finkelshte... on 07 Nov, 2017 10:45 PM

    Ilya Finkelshteyn's Avatar

    Actually you are correct, environment variables from environment and environment/global works the same way with matrix now. But we support this environment/global for historical reasons and also it is considered clearer expression when matrix exist in the configuration.

Reply to this discussion

Internal reply

Formatting help / Preview (switch to plain text) No formatting (switch to Markdown)

Attaching KB article:


Attached Files

You can attach files up to 10MB

If you don't have an account yet, we need to confirm you're human and not a machine trying to post spam.

Keyboard shortcuts


? 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

18 Jun, 2018 12:07 AM
17 Jun, 2018 04:04 PM
16 Jun, 2018 08:06 PM
16 Jun, 2018 07:30 PM
16 Jun, 2018 09:22 AM


15 Jun, 2018 09:31 PM
15 Jun, 2018 08:31 PM
15 Jun, 2018 04:29 PM
15 Jun, 2018 12:39 PM
15 Jun, 2018 12:37 PM
15 Jun, 2018 08:21 AM