[elbe-devel] [PATCH 3/4] Generate elbe-keyring.gpg if not building from cdrom

Torben Hohn torben.hohn at linutronix.de
Wed Jun 26 14:04:24 CEST 2019


On Wed, Jun 26, 2019 at 12:57:55PM +0200, dion at linutronix.de wrote:
> From: Olivier Dion <dion at linutronix.de>
> 
> Signed-off-by: Olivier Dion <dion at linutronix.de>

Acked-by: Torben Hohn <torben.hohn at linutronix.de>

i dont like how you set the whole GNUPGHOME, just to specify
--keyring ... 


> ---
>  elbepack/commands/init.py | 11 +++++++++++
>  1 file changed, 11 insertions(+)
> 
> diff --git a/elbepack/commands/init.py b/elbepack/commands/init.py
> index 08f77d1e..0b6bde73 100644
> --- a/elbepack/commands/init.py
> +++ b/elbepack/commands/init.py
> @@ -227,6 +227,17 @@ def run_command(argv):
>          os.system(
>              '7z x -o%s "%s" elbe-keyring.gpg' %
>              (out_path, opt.cdrom))
> +    else:
> +        keys = []
> +        for key in xml.all(".//raw-key"):
> +            keys.append(key.et.text)
> +        env = {"GNUPGHOME":out_path}
> +        command_out('gpg --import',
> +                    stdin="".join(keys),
> +                    env_add=env)
> +        keyring = os.path.join(out_path, "elbe-keyring.gpg")
> +        command_out('gpg --export --output "%s"' % keyring,
> +                    env_add=env)
>  
>      if opt.devel:
>          out_real = os.path.realpath(out_path)
> -- 
> 2.11.0
> 
> 
> _______________________________________________
> elbe-devel mailing list
> elbe-devel at linutronix.de
> https://lists.linutronix.de/mailman/listinfo/elbe-devel

-- 
Torben Hohn
Linutronix GmbH | Bahnhofstrasse 3 | D-88690 Uhldingen-Mühlhofen
Phone: +49 7556 25 999 18; Fax.: +49 7556 25 999 99

Hinweise zum Datenschutz finden Sie hier (Informations on data privacy 
can be found here): https://linutronix.de/kontakt/Datenschutz.php

Linutronix GmbH | Firmensitz (Registered Office): Uhldingen-Mühlhofen | 
Registergericht (Registration Court): Amtsgericht Freiburg i.Br., HRB700 
806 | Geschäftsführer (Managing Directors): Heinz Egger, Thomas Gleixner



More information about the elbe-devel mailing list