From ab593ba11aaf07f208063451c8e5186b54309370 Mon Sep 17 00:00:00 2001 From: Laurent Bonnans Date: Wed, 8 Jan 2020 12:24:37 +0100 Subject: Allow dots in ostree branch names and hw ids Signed-off-by: Laurent Bonnans --- classes/sota_sanity.bbclass | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/classes/sota_sanity.bbclass b/classes/sota_sanity.bbclass index 1339fb3..74973eb 100644 --- a/classes/sota_sanity.bbclass +++ b/classes/sota_sanity.bbclass @@ -14,10 +14,10 @@ def sota_check_variables_validity(status, d): import re import os.path - if d.getVar("OSTREE_BRANCHNAME") and re.match("^[a-zA-Z0-9_-]*$", d.getVar("OSTREE_BRANCHNAME")) is None: - status.addresult("OSTREE_BRANCHNAME Should only contain characters from the character set [a-zA-Z0-9_-].\n") - if d.getVar("SOTA_HARDWARE_ID") and re.match("^[a-zA-Z0-9_-]*$", d.getVar("SOTA_HARDWARE_ID")) is None: - status.addresult("SOTA_HARDWARE_ID Should only contain characters from the character set [a-zA-Z0-9_-].\n") + if d.getVar("OSTREE_BRANCHNAME") and re.match("^[a-zA-Z0-9._-]*$", d.getVar("OSTREE_BRANCHNAME")) is None: + status.addresult("OSTREE_BRANCHNAME Should only contain characters from the character set [a-zA-Z0-9._-].\n") + if d.getVar("SOTA_HARDWARE_ID") and re.match("^[a-zA-Z0-9._-]*$", d.getVar("SOTA_HARDWARE_ID")) is None: + status.addresult("SOTA_HARDWARE_ID Should only contain characters from the character set [a-zA-Z0-9._-].\n") if d.getVar("SOTA_CLIENT_FEATURES") is not None: for feat in d.getVar("SOTA_CLIENT_FEATURES").split(' '): if feat not in ("hsm", "serialcan", "ubootenv", ""): -- cgit v1.2.3-54-g00ecf