chore: update fork to allow other repos
diff --git a/hack/repos/fork b/hack/repos/fork
new file mode 100755
index 0000000..0682363
--- /dev/null
+++ b/hack/repos/fork
@@ -0,0 +1,30 @@
+#!/bin/bash -xe
+
+gh repo fork ${1} --org vexxhost
+
+REPOSITORY_ID_QUERY="{repository(owner: \"vexxhost\", name: \"${1##*/}\"){id}}"
+REPOSITORY_ID=$(gh api graphql -f query="${REPOSITORY_ID_QUERY}" -q .data.repository.id)
+
+gh api graphql -f query='
+mutation($repositoryId:ID!) {
+ createBranchProtectionRule(input: {
+ repositoryId: $repositoryId
+ pattern: "master"
+ requiresApprovingReviews: true
+ requiredApprovingReviewCount: 1
+ requiresConversationResolution: true
+ requiresLinearHistory: true
+ }) { clientMutationId }
+}' -f repositoryId=${REPOSITORY_ID}
+
+gh api graphql -f query='
+mutation($repositoryId:ID!) {
+ createBranchProtectionRule(input: {
+ repositoryId: $repositoryId
+ pattern: "stable/*"
+ requiresApprovingReviews: true
+ requiredApprovingReviewCount: 1
+ requiresConversationResolution: true
+ requiresLinearHistory: true
+ }) { clientMutationId }
+}' -f repositoryId=${REPOSITORY_ID}