-
Notifications
You must be signed in to change notification settings - Fork 12
140 lines (135 loc) · 4.83 KB
/
dargon2_docbot.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
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
name: docbot
on:
push:
tags:
- '*'
workflow_dispatch:
jobs:
# Job to update the documentation on docs.tmthecoder.dev for dargon2
update-docs-dargon2:
defaults:
run:
working-directory: dargon2
runs-on: ubuntu-latest
steps:
- uses: dart-lang/setup-dart@v1
- uses: actions/checkout@v2
- name: Activate Dartdoc
run: dart pub global activate dartdoc
- name: Install dependencies
run: dart pub get
- name: Generate Documentation
run: dartdoc
- name: Push Documentation
run: |
mkdir doc-src && git clone https://github.com/tmthecoder/docs doc-src
cd doc-src
echo "docs.tmthecoder.dev" > CNAME
git config user.name "Docbot"
git config user.email "[email protected]"
if [ -d dargon2/ ]; then rm -Rf dargon2/; fi
cp -R ../doc/api dargon2/
git remote add secure-origin https://${{ secrets.ACCESS_TOKEN }}@github.com/tmthecoder/docs
git add .
git commit -m "Updated documentation for dargon2" --allow-empty
git push secure-origin main
# Job to update the documentation on docs.tmthecoder.dev for dargon2_core
update-docs-dargon2_core:
needs: [ update-docs-dargon2 ]
defaults:
run:
working-directory: dargon2_core
runs-on: ubuntu-latest
steps:
- uses: dart-lang/setup-dart@v1
- uses: actions/checkout@v2
- name: Activate Dartdoc
run: dart pub global activate dartdoc
- name: Install dependencies
run: dart pub get
- name: Generate Documentation
run: dartdoc
- name: Push Documentation
run: |
mkdir doc-src && git clone https://github.com/tmthecoder/docs doc-src
cd doc-src
echo "docs.tmthecoder.dev" > CNAME
git config user.name "Docbot"
git config user.email "[email protected]"
if [ -d dargon2_core/ ]; then rm -Rf dargon2_core/; fi
cp -R ../doc/api dargon2_core/
git remote add secure-origin https://${{ secrets.ACCESS_TOKEN }}@github.com/tmthecoder/docs
git add .
git commit -m "Updated documentation for dargon2_core" --allow-empty
git push secure-origin main
# Job to update the documentation on docs.tmthecoder.dev for dargon2_interface
update-docs-dargon2_interface:
needs: [update-docs-dargon2_core]
defaults:
run:
working-directory: dargon2_interface
runs-on: ubuntu-latest
steps:
- uses: dart-lang/setup-dart@v1
- uses: actions/checkout@v2
- name: Activate Dartdoc
run: dart pub global activate dartdoc
- name: Install dependencies
run: dart pub get
- name: Generate Documentation
run: dartdoc
- name: Push Documentation
run: |
mkdir doc-src && git clone https://github.com/tmthecoder/docs doc-src
cd doc-src
echo "docs.tmthecoder.dev" > CNAME
git config user.name "Docbot"
git config user.email "[email protected]"
if [ -d dargon2_interface/ ]; then rm -Rf dargon2_interface/; fi
cp -R ../doc/api dargon2_interface/
git remote add secure-origin https://${{ secrets.ACCESS_TOKEN }}@github.com/tmthecoder/docs
git add .
git commit -m "Updated documentation for dargon2_interface" --allow-empty
git push secure-origin main
# Job to update the documentation on docs.tmthecoder.dev for dargon2_flutter
update-docs-dargon2_flutter:
needs: [update-docs-dargon2_interface]
defaults:
run:
working-directory: dargon2_flutter
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Cache Flutter dependencies
uses: actions/cache@v2
with:
path: /opt/hostedtoolcache/flutter
key: ${{ runner.OS }}-flutter-install-cache-${{ env.flutter_version }}
- uses: subosito/[email protected]
with:
channel: 'stable'
- name: Upgrade flutter
run: flutter upgrade
- name: Install dependencies
run: |
cd dargon2_flutter
flutter packages get
- name: Activate dartdoc
run: dart pub global activate dartdoc
- name: Generate Documentation
run: |
cd dargon2_flutter
dartdoc
- name: Push Documentation
run: |
mkdir doc-src && git clone https://github.com/tmthecoder/docs doc-src
cd doc-src
echo "docs.tmthecoder.dev" > CNAME
git config user.name "Docbot"
git config user.email "[email protected]"
if [ -d dargon2_flutter/ ]; then rm -Rf dargon2_flutter/; fi
cp -R ../dargon2_flutter/doc/api dargon2_flutter/
git remote add secure-origin https://${{ secrets.ACCESS_TOKEN }}@github.com/tmthecoder/docs
git add .
git commit -m "Updated documentation for dargon2_flutter" --allow-empty
git push secure-origin main