-
Notifications
You must be signed in to change notification settings - Fork 1
106 lines (106 loc) · 3.63 KB
/
main.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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
name: Build statistics
on:
workflow_dispatch:
push:
schedule:
- cron: '12 02 * * *'
jobs:
woocommerce:
runs-on: ubuntu-latest
steps:
- name: Set up Homebrew
id: set-up-homebrew
uses: Homebrew/actions/setup-homebrew@master
- run: brew install cloc
- uses: actions/checkout@v2
- run: kotlinc -script script.main.kts -- "https://github.com/woocommerce/woocommerce-android" "compileWasabiDebugKotlin"
working-directory: script
- uses: actions/upload-artifact@v2
with:
path: results/woocommerce-android.csv
wordpress:
runs-on: ubuntu-latest
steps:
- name: Set up Homebrew
id: set-up-homebrew
uses: Homebrew/actions/setup-homebrew@master
- run: brew install cloc
- uses: actions/checkout@v2
- run: kotlinc -script script.main.kts -- "https://github.com/wordpress-mobile/WordPress-Android" "compileWordpressWasabiDebugKotlin"
working-directory: script
- uses: actions/upload-artifact@v2
with:
path: results/WordPress-Android.csv
# simplenote:
# runs-on: ubuntu-latest
# steps:
# - name: Set up Homebrew
# id: set-up-homebrew
# uses: Homebrew/actions/setup-homebrew@master
# - run: brew install cloc
# - uses: actions/checkout@v2
# - run: kotlinc -script script.main.kts -- "https://github.com/Automattic/simplenote-android" "compileDebugKotlin"
# working-directory: script
# - uses: actions/upload-artifact@v2
# with:
# path: results/simplenote-android.csv
fluxc:
runs-on: ubuntu-latest
steps:
- name: Set up Homebrew
id: set-up-homebrew
uses: Homebrew/actions/setup-homebrew@master
- run: brew install cloc
- uses: actions/checkout@v2
- run: kotlinc -script script.main.kts -- "https://github.com/wordpress-mobile/WordPress-FluxC-Android" "compileDebugKotlin"
working-directory: script
- uses: actions/upload-artifact@v2
with:
path: results/WordPress-FluxC-Android.csv
wcstoreapp:
runs-on: ubuntu-latest
steps:
- name: Set up Homebrew
id: set-up-homebrew
uses: Homebrew/actions/setup-homebrew@master
- run: brew install cloc
- uses: actions/checkout@v2
- run: kotlinc -script script.main.kts -- "https://github.com/hichamboushaba/WCStoreApp" "compileDebugKotlin"
working-directory: script
- uses: actions/upload-artifact@v2
with:
path: results/WCStoreApp.csv
build:
runs-on: ubuntu-latest
name: "Build browser site"
needs: [ woocommerce, wordpress, fluxc, wcstoreapp ]
steps:
- uses: actions/checkout@v2
- uses: actions/download-artifact@v2
with:
path: results
- run: mv -v results/artifact/* results
- run: rm -rf results/artifact
- name: Get current date
id: date
run: echo "::set-output name=date::$(date +'%d/%m/%y')"
- name: Push updated statistics to remote
continue-on-error: true
run: |
git diff
git config --local user.email "action@github.com"
git config --local user.name "GitHub Action"
git add -A
git commit -m "Report update on ${{ steps.date.outputs.date }}"
git push
- uses: actions/setup-java@v1.4.3
with:
java-version: 1.8
- name: Distribution
run: ./gradlew dist
working-directory: browser
- name: GitHub Pages
uses: peaceiris/actions-gh-pages@v3.7.3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: browser/build/dist