IsProtectedBranch returns true if the branch name is main or master.
(branch string)
| 20 | |
| 21 | // IsProtectedBranch returns true if the branch name is main or master. |
| 22 | func IsProtectedBranch(branch string) bool { |
| 23 | return branch == "main" || branch == "master" |
| 24 | } |
| 25 | |
| 26 | // CreateBranch creates a new branch and switches to it. |
| 27 | func CreateBranch(dir, branchName string) error { |
no outgoing calls