-
Notifications
You must be signed in to change notification settings - Fork 4
49 lines (46 loc) · 1.58 KB
/
deliver-icons-to-spark-android.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
name: 📦 Deliver icons to Adevinta/spark-android
on:
workflow_dispatch:
push:
branches:
- main
paths:
- "assets/spark/icons/*"
env:
DIST: "build/android/dist/spark/icons"
jobs:
deliver_icons_to_spark_android:
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v3
with:
submodules: true
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: lts/Hydrogen
cache: "npm"
- name: Install svgo
run: npm -g install [email protected]
- name: Cleanup dist
run: |
rm -rf "$DIST"
mkdir -p "$DIST"
- name: Run svg2avd.main.kts
run: ./spark-android/scripts/svg2avd/svg2avd.main.kts --input="assets/spark/icons" --output="$DIST" --precision=2 --prefix="spark_icons_" --copyright="spark-android/scripts/svg2avd/COPYRIGHT.xml"
- name: Deliver Icons To Spark Android
uses: cpina/[email protected]
env:
SSH_DEPLOY_KEY: ${{ secrets.SSH_DEPLOY_KEY_SPARK_ANDROID }}
with:
source-directory: ${{ env.DIST }}
destination-github-username: "adevinta"
destination-repository-name: "spark-android"
user-email: ${{ secrets.API_GITHUB_COMMIT_EMAIL }}
commit-message: |
chore(avd): update icons
See ORIGIN_COMMIT from $GITHUB_REF
target-branch: chore-updated-icons
create-target-branch-if-needed: true
target-directory: "spark-icons/src/main/res/drawable"