7b18e5ec3b
If a kas-file inside a repo includes another kas-file form a repo which is not checked-out, and this 2nd repo can only be checked-out with an SSH-key, kas fails. This is, because the constructor of the Config class used to fetch missing repos already before the SSH-Agent was setup. This patch refactors the way in which kas checks-out repositories. This also required the Config class to be split into Context and Config, where the new Context is the build-Context, i.e. containing the environment of commands executed by kas and the new Config is the Config of kas itself, i.e. containing the repo dictionary. This way it is possible to initialize the context needed for SSH setup independently of the kas configuration. The commands ReposFetch and ReposCheckout are refactored into a SetupRepos command. This command parses the include files and successively checks-out needed repos and updates the config as long as repos are missing. The logic is taken directly from the constructor of the former Config class (with minor adaptations). Further refactoring will be needed to clean up the conceptual programming patterns (i.e. to keep the Macro-Style consistent), and to re-add the macro pattern regarding the above ReposFetch. Signed-off-by: Andreas Reichel <andreas.reichel.ext@siemens.com> |
||
---|---|---|
docs | ||
kas | ||
scripts | ||
tests | ||
.dockerignore | ||
.gitignore | ||
.pylintrc | ||
.travis.yml | ||
CHANGELOG.md | ||
CONTRIBUTING.md | ||
docker-entrypoint | ||
Dockerfile | ||
Dockerfile.isar | ||
LICENSE | ||
README.rst | ||
requirements_rtd.txt | ||
run-kas | ||
setup.py |
Setup tool for bitbake based projects ===================================== +------------+------------------+ | Branch | Build Status | +============+==================+ | ``master`` | |travis-master|_ | +------------+------------------+ | ``next`` | |travis-next|_ | +------------+------------------+ .. |travis-master| image:: https://travis-ci.org/siemens/kas.svg?branch=master .. _travis-master: https://travis-ci.org/siemens/kas/branches .. |travis-next| image:: https://travis-ci.org/siemens/kas.svg?branch=next .. _travis-next: https://travis-ci.org/siemens/kas/branches This tool provides an easy mechanism to setup bitbake based projects. The OpenEmbedded tooling support starts at step 2 with bitbake. The downloading of sources and then configuration has to be done by hand. Usually, this is explained in a README. Instead kas is using a project configuration file and does the download and configuration phase. Key features provided by the build tool: - clone and checkout bitbake layers - create default bitbake settings (machine, arch, ...) - launch minimal build environment, reducing risk of host contamination - initiate bitbake build process See the `kas documentation <https://kas.readthedocs.io>`_ for further details.