Skip to content

Commit 468d348

Browse files
committed
README: add more info about local testing
Signed-off-by: Jakub Kicinski <[email protected]>
1 parent b7d57ae commit 468d348

File tree

1 file changed

+26
-7
lines changed

1 file changed

+26
-7
lines changed

README.rst

Lines changed: 26 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -36,11 +36,34 @@ Having everyone test their patches locally allows for better
3636
scaling (no need for big central infrastructure) and hopefully
3737
creates an incentive for contributing.
3838

39+
Running locally
40+
===============
41+
42+
`ingest_mdir.py` can ingest patches and run the checks locally
43+
(by the developers on their machines). `ingest_mdir.py` should be pointed
44+
at a directory and run all the checks on patches that directory contains
45+
(patches are expected to be generated by `git format-patch`).
46+
47+
Example:
48+
49+
.. code-block:: bash
50+
51+
cd $linux
52+
git format-patch HEAD~4.. -o /tmp/my-series/ --subject-prefix="PATCH net-next"
53+
git checkout net-next/master -b test
54+
55+
cd $nipa
56+
./ingest_mdir.py --mdir /tmp/my-series/ --tree $linux
57+
58+
Note that we need to check out the linux tree to a branch that matches the base
59+
on which we intend the patches to be applied. NIPA does not know what to reset
60+
the tree to, it will just try to apply the patches to whatever branch is
61+
currently checked out in the `$linux` repo.
62+
3963
Structure
4064
=========
4165

42-
The project is split into multiple programs with different
43-
uses.
66+
The project is split into multiple programs with different uses.
4467

4568
`pw_poller.py` fetches emails from patchwork and runs tests in worker
4669
threads. There is one worker thread for each tree, enabling testing
@@ -52,11 +75,7 @@ and sub-dirs for each patch.
5275
Once tests are done another daemon - `pw_upload.py` uploads the results
5376
as checks to patchwork.
5477

55-
`ingest_mdir.py` is supposed to serve the purpose of testing
56-
patches locally, it can be pointed at a directory and run all the
57-
checks on patches that directory contains (patches are expected to
58-
be generated by `git format-patch`). `ingest_mdir.py` has not been
59-
tested in a while so it's probably broken.
78+
`ingest_mdir.py` combines all the stages for local use.
6079

6180
Configuration
6281
=============

0 commit comments

Comments
 (0)