@@ -77,7 +77,10 @@ reviewers string is formatted for use with [GitHub's gh
7777CLI] ( https://cli.github.com/ ) .
7878
7979 $ docker run --rm -i reviewer-selector < samples/sample.diff
80+ No REPO_URL in environment, using built-in rules ...
8081 No DIFF_URL in environment, reading from stdin ...
82+ No ORG_NAME in environment, using # as group prefix ...
83+ No REPO_NAME or TARGET_BRANCH_NAME in environment, not matching repository-based rules ...
8184 No PR_URL or GITHUB_TOKEN in environment, outputing to stdout ...
8285 @example-group,shtrom
8386
@@ -91,7 +94,10 @@ piped into the container.
9194 | docker run --rm -i \
9295 -v ./herald_rules.real.json:/app/herald_rules.json \
9396 reviewer-selector
97+ No REPO_URL in environment, using built-in rules ...
9498 No DIFF_URL in environment, reading from stdin ...
99+ No ORG_NAME in environment, using # as group prefix ...
100+ No REPO_NAME or TARGET_BRANCH_NAME in environment, not matching repository-based rules ...
95101 No PR_URL or GITHUB_TOKEN in environment, outputing to stdout ...
96102 @android-reviewers
97103
@@ -104,6 +110,16 @@ The container's behaviour can be entirely parametrised via environment variables
104110 -e GITHUB_TOKEN=[REDACTED] reviewer-selector
105111 Adding reviewers to https://github.com/mozilla-firefox/infra-testing/pull/30 ...
106112
107- If ` DIFF_URL ` is given, it will be fetched and passed into the selector's
108- stdin. If ` GITHUB_TOKEN ` and ` PR_URL ` are provided, the container will attempt
109- to set the reviewers on the target PR.
113+ * If ` DIFF_URL ` is given, it will be fetched and passed into the selector's
114+ stdin.
115+ * If ` GITHUB_TOKEN ` and ` PR_URL ` are provided, the container will attempt
116+
117+ Some other optional behaviours can be triggered by providing additional context
118+ in environment variables:
119+ * If ` ORG_NAME ` is passed, it will be used to scope reviewers groups to that
120+ org.
121+ * If ` REPO_NAME ` and ` TARGET_BRANCH_NAME ` are provided, rules that specifically
122+ match a given repository and/or branch will also be applied.
123+ * If ` REPO_URL ` is given, the script will attempt to fetch a rules file from
124+ the ` main ` branch of the repository. If it fails, it will fallback to
125+ built-in rules. to set the reviewers on the target PR.
0 commit comments