File tree 2 files changed +29
-0
lines changed
2 files changed +29
-0
lines changed Original file line number Diff line number Diff line change
1
+
2
+ DOCS_LINK_MESSAGE = """
3
+
4
+ Docs for this Pull Request will be rendered here:
5
+
6
+ https://storage.googleapis.com/envoy-pr/%s/docs/index.html
7
+
8
+ The docs are (re-)rendered each time the CI `envoy-presubmit (precheck docs)` job completes.
9
+
10
+ """
11
+
12
+ def should_add_docs_link (action , issue_title ):
13
+ return (
14
+ action == 'opened'
15
+ and issue_title .startswith ("docs:" ))
16
+
17
+ def add_docs_link (issue_number ):
18
+ github .issue_create_comment (DOCS_LINK_MESSAGE % issue_number )
19
+
20
+ def _pr (action , issue_number , issue_title ):
21
+ if should_add_docs_link (action , issue_title ):
22
+ add_docs_link (issue_number )
23
+
24
+ def _add_docs (issue_number ):
25
+ add_docs_link (issue_number )
26
+
27
+ handlers .pull_request (func = _pr )
28
+ handlers .command (name = 'docs' , func = _add_docs )
Original file line number Diff line number Diff line change @@ -4,6 +4,7 @@ use("github.com/repokitteh/modules/assign.star")
4
4
use ("github.com/repokitteh/modules/review.star" )
5
5
use ("github.com/repokitteh/modules/wait.star" )
6
6
use ("github.com/envoyproxy/envoy/ci/repokitteh/modules/azure_pipelines.star" , secret_token = get_secret ('azp_token' ))
7
+ use ("github.com/envoyproxy/envoy/ci/repokitteh/modules/docs.star" )
7
8
use ("github.com/envoyproxy/envoy/ci/repokitteh/modules/newpr.star" )
8
9
use (
9
10
"github.com/envoyproxy/envoy/ci/repokitteh/modules/ownerscheck.star" ,
You can’t perform that action at this time.
0 commit comments