How do you use `vars` and what is the precedence between levels?
BeginnerConceptContexts, Expressions, Env & Outputs
Answer
Configuration variables are plain-text values set at organization, repository and environment level, read with ${{ vars.NAME }}. Precedence: environment over repository over organization. They are not masked in logs and should be considered readable by anyone who can see the workflow output. Use them for region names, account IDs, cluster names and feature flags; never for credentials.
gh variable set AWS_REGION --body ap-south-1
gh variable set CLUSTER_NAME --env prod --body shack-prod
More on Contexts, Expressions, Env & Outputs
List the available contexts and what each holds.BeginnerWhich contexts can you use in which keys? Give two examples that trip people up.AdvancedWhat are the expression operators and how do comparisons coerce types?IntermediateHow do you write a ternary in GitHub Actions expressions?IntermediateWhat do `contains`, `startsWith`, `endsWith`, `format` and `join` do?BeginnerWhat are object filters (`.*`) and how are they useful?Intermediate