![]() Rewrite the scripts that gather the metrics to be more generic. Extract the metrics repository cloning out so that we don't have to repeatedly clone it. Make the scripts parse their arguments using getopt and be more specific about what they're passed. In particular, this means that for the patch review run we pass the _repository_ that we're scanning so we can do git operations on it, and the base of the _layers_ (either a layer, or a directory containing layers) so we know what to scan. Be more clever when identifying what commits we need to analyse for patch review: instead of iterating through a set randomly, we can keep the revision list sorted and the checkout operations are a lot faster. Remove the commit/file count metric addition as patchreview itself does that now. Add an explicit --push option so it's easy to test the scripts in isolation without pushing. Signed-off-by: Ross Burton <ross.burton@arm.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> |
||
---|---|---|
janitor | ||
lava | ||
lava-templates | ||
scripts | ||
.gitignore | ||
config-intelqa-x86_64-lava.json | ||
config.json | ||
LICENSE.GPL-2.0-only | ||
local-example.json | ||
README | ||
SECURITY.md |
This repo is designed to work in conjuction yocto-autobuilder. Whilst yocto-autobuilder is designed to cover all releases, this repo has a branch per release and contains the hooks that do the actual build configuration and execution.
pre-commit-hook.sh can be used to verify the JSON before committing, symlink this to .git/hooks/pre-commit (ln -s ../../scripts/pre-commit-hook.sh .git/hooks/pre-commit).
Its likely most users will end up having to customise this repository for their needs. The scripts themselves should be more generically reusable, the config.json, less so as it represents the Yocto Project Autobuilder test matrix.
There are two customisation options possible, one is through variable substitution, the other is through overlaying configuration files. The standard config.json tries to at least allow substitution of the paths. A local-example.json is included to show how you could override these from a separate config file, simply passing:
ABHELPER_JSON="config.json local-example.json"
into the environment of the autobuilder.
ABHELPER_JSON="config.json /some/location/local.json"
would also allow customisation.
Authors: Richard Purdie richard.purdie@linuxfoundation.org Joshua Lock joshua.g.lock@intel.com
Contributions:
Patches for this code should be sent to the yocto@lists.yoctoproject.org mailing list with [yocto-autobuilder-helper] in the subject. This can be configured automatically with the following commands:
git config --local --add format.subjectprefix 'PATCH yocto-autobuilder-helper' git config --local --add sendemail.to yocto@lists.yoctoproject.org