-
Notifications
You must be signed in to change notification settings - Fork 37
61 lines (55 loc) · 1.96 KB
/
update-docs.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
name: Update GitBook Docs
on:
repository_dispatch:
types: docs_update
workflow_dispatch:
permissions:
contents: write
pull-requests: write
jobs:
update-documentation:
runs-on: ubuntu-latest
steps:
- uses: actions/setup-dotnet@v3
with:
dotnet-version: 7
- uses: actions/checkout@v3
with:
repository: NethermindEth/nethermind
submodules: recursive
path: nethermind
- uses: actions/checkout@v3
with:
path: docs
- name: Generate new docs
run: |
cd nethermind/
cd src/Nethermind/Nethermind.GitBook
dotnet run -c Release Nethermind.GitBook.csproj
- name: Copy updated content to root
run: |
DOCS_PATH=nethermind/src/Nethermind/Nethermind.GitBook/docs
cp $DOCS_PATH/ethereum-client/json-rpc/* docs/ethereum-client/json-rpc/
cp $DOCS_PATH/ethereum-client/metrics/* docs/ethereum-client/metrics
cp $DOCS_PATH/ethereum-client/configuration/* docs/ethereum-client/configuration
cp $DOCS_PATH/nethermind-utilities/cli/* docs/nethermind-utilities/cli
- name: Create Pull Request
uses: peter-evans/[email protected]
with:
token: ${{ secrets.GITHUB_TOKEN }}
path: docs
commit-message: Update documentation
body: |
Nethermind documentation has been updated.
- Auto-generated by [create-pull-request][1]
[1]: https://github.com/peter-evans/create-pull-request
title: 'Updating Documentation'
labels: documentation
author: ${{ github.actor }} <${{ github.actor }}@users.noreply.github.com>
committer: GitHub <[email protected]>
branch: docs-update
branch-suffix: short-commit-hash
base: master
- name: Checking Outputs
run: |
echo "Pull Request Number - ${{ env.PULL_REQUEST_NUMBER }}"