-
Notifications
You must be signed in to change notification settings - Fork 1
36 lines (34 loc) · 1.15 KB
/
auto-update-assets.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
name: auto-update-assets
on:
push:
branches:
- 'main'
schedule:
- cron: '0 0 * * *'
jobs:
builder:
runs-on: ubuntu-latest
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
steps:
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Update Client Extensions Samples
working-directory: ./lfr/pkg/assets/tpl/cx
run: |
rm -r liferay-portal
git clone --depth 1 --filter=blob:none --no-checkout https://github.com/liferay/liferay-portal
cd liferay-portal
git sparse-checkout init --no-cone
git sparse-checkout set workspaces/liferay-sample-workspace/client-extensions
git checkout master
rm -r .git
- name: Commit Client Extensions Changes
run: |
git config --global user.name 'github-actions[bot]'
git config --global user.email '41898282+github-actions[bot]@users.noreply.github.com'
git add ./lfr/pkg/assets/tpl/cx/
git commit -am "chore: auto update client extensions samples" || echo "We're good for now. See you next time!"
git push