Skip to content

Commit 56f4f8f

Browse files
Changed to using PRs due to branch protection (#826)
2 parents b5e706e + 642720d commit 56f4f8f

File tree

1 file changed

+11
-17
lines changed

1 file changed

+11
-17
lines changed

.github/workflows/generate_algorithm_families.yml

Lines changed: 11 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ jobs:
1313

1414
permissions:
1515
contents: write
16+
pull-requests: write
1617

1718
steps:
1819
- name: Checkout repository
@@ -29,20 +30,13 @@ jobs:
2930
working-directory: tools/src/main/python
3031
run: python3 algorithmFamilyGeneration.py
3132

32-
- name: Check for changes and commit
33-
run: |
34-
SCHEMA_FILE="schema/cryptography-defs.schema.json"
35-
36-
# Add the file
37-
git add "$SCHEMA_FILE"
38-
39-
# Check if there are staged changes
40-
if git diff --staged --quiet; then
41-
echo "No changes to algorithm families"
42-
else
43-
echo "Committing algorithm family changes"
44-
git config --local user.email "github-actions[bot]@users.noreply.github.com"
45-
git config --local user.name "github-actions[bot]"
46-
git commit -m "chore: update algorithm families [skip ci]"
47-
git push
48-
fi
33+
- name: Create Pull Request
34+
uses: peter-evans/create-pull-request@v6
35+
with:
36+
token: ${{ secrets.GITHUB_TOKEN }}
37+
commit-message: "chore: update algorithm families [skip ci]"
38+
branch: "update-algorithm-families"
39+
title: "chore: update algorithm families"
40+
body: "This PR updates `schema/cryptography-defs.schema.json` with the latest algorithm families generated from `schema/cryptography-defs.json`."
41+
base: "master"
42+
delete-branch: true

0 commit comments

Comments
 (0)