[GitHub] Protect this branch

YuLim·2023년 2월 14일
1

GitHub 레포에 아래와 같은 창이 떴다.

Your main branch isn't protected
Protect this branch from force pushing or deletion, or require status checks before merging.
해석하면
main 브랜치가 보호되지 않습니다
이 branch를 강제로 누르거나 삭제하지 않도록 보호하거나 병합하기 전에 상태 확인이 필요합니다.

버튼을 누르면 아래와 같은 창이 나온다.

Protect your most important branches
Branch protection rules define whether collaborators can delete or force push to the branch and set requirements for any pushes to the branch, such as passing status checks or a linear commit history.
Your GitHub Free plan can only enforce rules on its public repositories, like this one.
해석
가장 중요한 branchs 보호
branch 보호 규칙은 공동작업자가 branch를 삭제하거나 강제로 푸시할 수 있는지 여부를 정의하고 상태 검사 또는 선형 커밋 기록 전달과 같은 branch 푸시에 대한 요구 사항을 설정합니다.
GitHub Free 요금제는 이와 같은 public repositories에 대해서만 규칙을 적용할 수 있습니다.

Rule을 적용할 branch에 직접 push를 하지 않고 PR로만 push를 주게 하는 등의 제약을 걸 수 있다.

※ GitHub에서만 주는 제약으로 로컬에서는 제약을 받지 않는다.

profile
개인 공부 기록장

0개의 댓글