[elbe-devel] [PATCH 2/9] finetuning: imeplement projcmd for project-finetuning
Manuel Traut
manut at linutronix.de
Fri Nov 30 14:44:40 CET 2018
On 17:28 Wed 28 Nov , Torben Hohn wrote:
> add projcmd to project-finetuning, that execute commands
> in project directory using shell.
I just realized that there is project-finetuning and image-finetuning.
Please describe that in the cover-letter of the queue. Including
information what kind of actions are available for the different types
of finetuning.
> Signed-off-by: Torben Hohn <torben.hohn at linutronix.de>
> ---
> elbepack/finetuning.py | 18 ++++++++++++++++++
> schema/dbsfed.xsd | 7 +++++++
> 2 files changed, 25 insertions(+)
>
> diff --git a/elbepack/finetuning.py b/elbepack/finetuning.py
> index e4f889a2..8ba903f0 100644
> --- a/elbepack/finetuning.py
> +++ b/elbepack/finetuning.py
> @@ -472,6 +472,24 @@ class UpdatedAction(FinetuningAction):
> FinetuningAction.register(UpdatedAction)
>
>
> +class ProjCmdAction(FinetuningAction):
> +
> + tag = 'projcmd'
> +
> + def __init__(self, node):
> + FinetuningAction.__init__(self, node)
> +
> + def execute(self, _log, _buildenv, _target):
> + raise NotImplementedError("<projcmd> may only be "
> + "used in <project-finetuning>")
> +
> + def execute_prj(self, log, _buildenv, _target, builddir):
> + log.do('cd "%s"; %s' % (builddir, self.node.et.text))
>
> +FinetuningAction.register(ProjCmdAction)
> +
> +
> def do_finetuning(xml, log, buildenv, target):
>
> if not xml.has('target/finetuning'):
> diff --git a/schema/dbsfed.xsd b/schema/dbsfed.xsd
> index 85cbaff0..f0b244d8 100644
> --- a/schema/dbsfed.xsd
> +++ b/schema/dbsfed.xsd
> @@ -1858,6 +1858,13 @@
> </documentation>
> </annotation>
> </element>
> + <element name="projcmd" type="rfs:string" minOccurs="0">
> + <annotation>
> + <documentation>
> + cd into the project directory, and execute the command via /bin/sh
> + </documentation>
> + </annotation>
> + </element>
> </choice>
> </group>
>
> --
> 2.11.0
>
>
> _______________________________________________
> elbe-devel mailing list
> elbe-devel at linutronix.de
> https://lists.linutronix.de/mailman/listinfo/elbe-devel
More information about the elbe-devel
mailing list