Merge pull request #39 from bartvdbraak/feat/unlighthouse

fix: Author was incorrectly assigned to commit
This commit is contained in:
Bart van der Braak 2023-06-12 04:23:50 +02:00 committed by GitHub
commit aa6be4ad06
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -20,12 +20,14 @@ jobs:
- name: Delete directory in gh-pages
if: github.event.ref_type == 'branch'
run: |
git config --global user.email "41898282+github-actions[bot]@users.noreply.github.com"
git config --global user.name "github-actions[bot]"
git fetch --all
git checkout gh-pages
branchName=$(echo "${{ github.event.ref }}" | sed -e 's,^refs/heads/,,')
if [ -d "./${branchName}" ]; then
git rm -rf --ignore-unmatch "${branchName}"
git commit -m "Cleanup directory for deleted branch ${branchName}" --author="github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>"
git commit -m "Cleanup directory for deleted branch ${branchName}"
git push origin gh-pages
else
echo "Directory doesn't exist for branch ${branchName}"