Skip to content

Commit f21487f

Browse files
Massimiliano Pippimasci
Massimiliano Pippi
authored andcommitted
deploy on push
1 parent f855fea commit f21487f

File tree

1 file changed

+18
-7
lines changed

1 file changed

+18
-7
lines changed

.github/workflows/docs.yaml

Lines changed: 18 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,18 @@
11
name: docs
22

3+
paths:
4+
# existing docs
5+
- 'docs/**'
6+
# changes to the cli reference generator
7+
- 'docsgen/**'
8+
# potential changes to commands documentation
9+
- 'cli/**'
10+
# potential changes to gRPC documentation
11+
- 'rpc/**'
12+
313
on:
414
pull_request:
5-
types:
6-
- opened
7-
- synchronize
8-
- closed
9-
paths:
15+
paths: &p
1016
# existing docs
1117
- 'docs/**'
1218
# changes to the cli reference generator
@@ -15,6 +21,11 @@ on:
1521
- 'cli/**'
1622
# potential changes to gRPC documentation
1723
- 'rpc/**'
24+
push:
25+
branches:
26+
- master
27+
paths:
28+
<<: *p
1829

1930
jobs:
2031
build:
@@ -67,8 +78,8 @@ jobs:
6778
run: task docs:build
6879

6980
- name: Deploy
70-
# publish docs only when PR is merged
71-
if: github.event.pull_request.merged == true
81+
# publish docs only when PR is merged on master
82+
if: github.event_name == 'push'
7283
uses: peaceiris/actions-gh-pages@v3
7384
with:
7485
github_token: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)