Skip to content

Commit da07d63

Browse files
committed
!fixup: document NIXPKGS_REVIEW_PRE_BUILD_FILTER
1 parent 7c07e78 commit da07d63

File tree

2 files changed

+17
-0
lines changed

2 files changed

+17
-0
lines changed

README.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -281,8 +281,23 @@ $ nixpkgs-review pr --skip-packages-regex 'linux_.*' 51292
281281
`-p`, `-P`, `--package-regex` and `--skip-package-regex` can be used together, in which case
282282
the matching packages will merged.
283283

284+
<<<<<<< HEAD
284285
Full documentation for regex matching syntax can be found
285286
[here](https://docs.python.org/3/library/re.html#regular-expression-syntax).
287+
=======
288+
## Filter plugins
289+
290+
After `nixpkgs-review` evaluates the set of changed packages but before it performs a build, it
291+
can interact with a set of plugins that can modify the set of packages. Such plugins should
292+
register themselves by setting the environment variable `NIXPKGS_REVIEW_PRE_BUILD_FILTER` to
293+
a colon-separated list of executables. Each executable called in order and piped a JSON
294+
structure containing `nixpkgs-review`'s internal representation of the package set, can modify
295+
it arbitrarily, and should return a new copy of the same JSON structure back on stdout.
296+
297+
Note: this interface is UNSTABLE and we make NO BACKWARD OR FORWARD COMPATIBILITY PROMISES
298+
about the structure of the JSON between versions of nixpkgs-review.
299+
300+
>>>>>>> ea1f67e (!fixup: document NIXPKGS_REVIEW_PRE_BUILD_FILTER)
286301
287302
## Running tests
288303

nixpkgs_review/report.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -162,6 +162,8 @@ def upload_build_logs(self, github_client: GithubClient, pr: Optional[int]) -> N
162162
)
163163
pkg.log_url = gist["html_url"]
164164
except urllib.error.HTTPError:
165+
# This is possible due to rate-limiting or a failure of that sort.
166+
# It should not be fatal.
165167
traceback.print_exc(file=sys.stderr)
166168
else:
167169
print(f"Log content for {pkg} was empty", file=sys.stderr)

0 commit comments

Comments
 (0)