forked from ubiquity/ubiquity-dollar
-
Notifications
You must be signed in to change notification settings - Fork 0
52 lines (44 loc) · 1.34 KB
/
generate-doc.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
name: Auto Generate Doc
on:
workflow_dispatch:
push:
branches:
- development
paths:
- '**.sol'
jobs:
generate-doc:
name: Generate Doc
if: github.repository == 'ubiquity/ubiquity-dollar'
runs-on: ubuntu-22.04
permissions:
contents: write
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: "18.14.1"
- name: Setup Foundry
uses: foundry-rs/foundry-toolchain@v1
with:
version: nightly-5be158ba6dc7c798a6f032026fe60fc01686b33b
- name: Yarn Install
run: yarn install --mode=skip-build && yarn allow-scripts
- name: Generate Docs
run: yarn workspace @ubiquity/contracts docs
- name: Push docs changed
run: |
git config --global user.email "github-actions[bot]@users.noreply.github.com"
git config --global user.name "github-actions[bot]"
echo "Check git information"
git status
git branch -avv
git log --graph --pretty=oneline --abbrev-commit --all -20
echo "git diff"
git diff
git add .
git commit -m "docs: auto generate NATSPEC docs"
echo "do git push to development branch"
git push origin development