From 838636d48e8a48a0e3d66ee93c974aa2942f8e41 Mon Sep 17 00:00:00 2001 From: Lucas Menendez Date: Wed, 8 Nov 2023 16:19:15 +0100 Subject: [PATCH] include 'ceremony/' prefix to every ceremony branch and only execute the create ceremony action under that condition --- .github/workflows/create-ceremony.yml | 3 ++- scripts/create-env.sh | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/create-ceremony.yml b/.github/workflows/create-ceremony.yml index 493af23..651d26e 100644 --- a/.github/workflows/create-ceremony.yml +++ b/.github/workflows/create-ceremony.yml @@ -4,6 +4,7 @@ on: jobs: compile-and-prepare: runs-on: ubuntu-latest + if: ${{ startsWith(github.ref, 'ceremony/') }} steps: - name: Checkout the repository uses: actions/checkout@v4 @@ -20,7 +21,7 @@ jobs: with: commit_message: Create '${{ github.ref }}' ceremony commit_options: '--no-verify' - commit_user_name: Voceremony Bot + commit_user_name: ${{ github.actor }} - name: Create PR to end ceremony run: gh pr create -B main -t "$PR_TITLE" -b "$PR_BODY" -l "$PR_LABELS" -a "$PR_ASSIGNEES" env: diff --git a/scripts/create-env.sh b/scripts/create-env.sh index 1073a37..63f01c6 100644 --- a/scripts/create-env.sh +++ b/scripts/create-env.sh @@ -56,11 +56,11 @@ cp $input_ptau $input_folder/$ptau_file echo "TARGET_CIRCUIT=$input_folder/$circuit_file INPUT_PTAU=$input_folder/$ptau_file -CEREMONY_BRANCH=$ceremony_branch +CEREMONY_BRANCH=ceremony/$ceremony_branch CONTRIBUTIONS_PATH=$contributions_path OUTPUT_PATH=$output_path" > ceremony.env -git checkout -b $ceremony_branch +git checkout -b ceremony/$ceremony_branch git add -f ceremony.env $input_folder/$circuit_file $input_folder/$ptau_file git commit -m "Initialize ceremony" git push origin $ceremony_branch