Merge remote-tracking branch 'origin/main' into chore-updated-icons #44
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: '🎨 PR icon updates' | |
on: | |
push: | |
branches: [ "chore-updated-icons" ] | |
concurrency: | |
group: ${{ github.head_ref || github.run_id }} | |
cancel-in-progress: true | |
env: | |
GH_TOKEN: ${{ github.token }} | |
FILE: 'spark-icons/src/main/kotlin/com/adevinta/spark/icons/SparkIcons.kt' | |
jobs: | |
pr-icon-updates: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
ref: chore-updated-icons | |
fetch-depth: 0 | |
- run: gh pr create --fill | |
continue-on-error: true | |
- run: | | |
./scripts/spark-icons-kt/spark-icons-kt.main.kts --input=spark-icons/src/main/res/drawable --output="$FILE" --copyright=scripts/spark-icons-kt/COPYRIGHT.kt | |
if ! git diff --quiet --exit-code -- "$FILE" ; | |
then | |
git config user.name 'spark-ui-bot' | |
git config user.email '[email protected]' | |
git commit "$FILE" -m "🎨 Update `SparkIcons.kt`" | |
git show | |
git push | |
echo "::notice::UPDATED" | |
else | |
echo "::notice::UP-TO-DATE" | |
fi |