]> code.ossystems Code Review - openembedded-core.git/commitdiff
recipetool: Skip common source files in guess_license
authorStefan Herbrechtsmeier <stefan.herbrechtsmeier@weidmueller.com>
Fri, 8 Oct 2021 07:48:26 +0000 (09:48 +0200)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Thu, 14 Oct 2021 10:48:35 +0000 (11:48 +0100)
Signed-off-by: Stefan Herbrechtsmeier <stefan.herbrechtsmeier@weidmueller.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
scripts/lib/recipetool/create.py

index e88a4253da8792eeada48e0932a803b275249e7e..83cf25d9b78d5e67b9fbb30780904267bce5c5f2 100644 (file)
@@ -1114,6 +1114,8 @@ def guess_license(srctree, d):
     licfiles = []
     for root, dirs, files in os.walk(srctree):
         for fn in files:
+            if fn.endswith(".html") or fn.endswith(".js") or fn.endswith(".json") or fn.endswith(".svg") or fn.endswith(".ts"):
+                continue
             for spec in licspecs:
                 if fnmatch.fnmatch(fn, spec):
                     fullpath = os.path.join(root, fn)