Skip to content

Commit 7be029b

Browse files
committed
Attempt 1 using gh api
1 parent d1781f0 commit 7be029b

File tree

1 file changed

+8
-12
lines changed

1 file changed

+8
-12
lines changed

.github/workflows/commit-tests.yml

Lines changed: 8 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -40,20 +40,16 @@ jobs:
4040
git config --global user.name "Application Collection Bot"
4141
git config --global user.email "[email protected]"
4242
43-
- name: Import GPG key
44-
id: import_gpg
45-
uses: crazy-max/ghaction-import-gpg@v2
46-
with:
47-
git_user_signingkey: true
48-
git_commit_gpgsign: true
49-
env:
50-
GPG_PRIVATE_KEY: ${{ env.PRIVATE_KEY }}
51-
5243
- name: Generate empty commit
5344
id: generate-images
5445
env:
5546
GH_TOKEN: ${{ steps.create-token.outputs.token }}
5647
run: |
57-
gh auth setup-git
58-
git commit --allow-empty -m "Signed commit test"
59-
git push origin gh-app-tests
48+
export SHA=$( git rev-parse gh-app-tests:. )
49+
export CONTENT=$( base64 -i . )
50+
gh api --method PUT /repos/:owner/:repo/contents/. \
51+
--field message="Signed commit test" \
52+
--field content="$CONTENT" \
53+
--field encoding="base64" \
54+
--field branch="gh-app-tests" \
55+
--field sha="$SHA"

0 commit comments

Comments
 (0)