From 17f9ac7428443db4b7b9a32e432cd6796fb41470 Mon Sep 17 00:00:00 2001 From: "Karl W. Schulz" Date: Mon, 13 Feb 2023 14:48:56 -0600 Subject: [PATCH] Update license header tool to not include a space after comment if rest of line is blank. Needed to make python formatting check happy. Signed-off-by: Karl W. Schulz [ROCm/rocprofiler-compute commit: 980fb08c9257efb6f9a33731faded75e6d169275] --- projects/rocprofiler-compute/utils/update_license.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/projects/rocprofiler-compute/utils/update_license.py b/projects/rocprofiler-compute/utils/update_license.py index 9594823b83..4342508c4e 100755 --- a/projects/rocprofiler-compute/utils/update_license.py +++ b/projects/rocprofiler-compute/utils/update_license.py @@ -25,7 +25,10 @@ def cacheLicenseFile(infile, comment="#"): license = "" with open(infile, "r") as file_in: for line in file_in: - license += comment + " " + line + license += comment + if line.strip() != "": + license += " " + license += line return license