github-community-projects / github-community-projects/safe-settings

Dynamic Context Naming in required_status_checks Based on Repository Name

Open
#860 0 comments 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
JavaScript
Stars
921
Forks
226
Avg merge
18h 3m
Merged PRs (30d)
14

Description

## Prerequisites:

* Is the functionality available in the GitHub UI? If so, please provide a link to information about the feature.

yes, under static checks of branch protection for mandating the checks as required.
where the name of the static checks are dynamic and so unable to define the dynamic naming in required_static_checks: => context:

Image

## New Feature

required_static_checks is only allowed with hardcoded or definite values only and we have scenario for each repo we have repo specific static checks.

for eg: we have PR test&build running in ado pipelines and the pipeline name is same as github repo name itself and hence the static check name as well, so if i want to define this pr build and test as mandate pr check, i would need to 1:1 repo:yaml file for branch protection rules to have unique static_checks naming.

Atleast i believe in the safe-settings, the repo name (suborgrepos) while getting applied in each repo with the respective branch protection rules and so is it possible to use the variable where the repo name is stored to apply this settings as the name for required_static_checks => context as well ?

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.