Skip to content

alignment

alignment #72

Workflow file for this run

name: Alignment
on:
repository_dispatch:
types: [alignment]
jobs:
alignment:
runs-on: ubuntu-latest
steps:
- name: Create GitHub App Token
uses: actions/[email protected]
id: generate-token
with:
app-id: ${{ secrets.GH_APP_ID }}
private-key: ${{ secrets.GH_APP_KEY }}
- uses: actions/checkout@v3
with:
token: ${{ steps.generate-token.outputs.token }}
submodules: recursive
- run: |
git config --global user.name "DemyCode"
git config --global user.email "[email protected]"
git checkout -b ${{ github.event.client_payload.branch }} || git checkout ${{ github.event.client_payload.branch }}
cd ${{ github.event.client_payload.repository }}
git checkout ${{ github.event.client_payload.branch }}
cd ..
git add ${{ github.event.client_payload.repository }}
COMMIT_MESSAGE="${{ github.event.client_payload.message }}"
if [ ${{ startsWith(github.event.client_payload.message, 'chore(release):') }} = true ]; then
COMMIT_MESSAGE=${COMMIT_MESSAGE/release/${{ github.event.client_payload.repository }}}
fi
git commit -m "${COMMIT_MESSAGE}"
git push origin ${{ github.event.client_payload.branch }} || git push --set-upstream origin ${{ github.event.client_payload.branch }}