From 0cc588690605e076e7dd7497516f0969618c13f2 Mon Sep 17 00:00:00 2001 From: ofriedma <48631098+ofriedma@users.noreply.github.com> Date: Thu, 23 Feb 2023 15:39:39 +0200 Subject: [PATCH] CI: Enforce writing licenses inside source files (#410) --- build_tools/check-sources.sh | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/build_tools/check-sources.sh b/build_tools/check-sources.sh index afac3cd2c2..69a7d8ef9e 100755 --- a/build_tools/check-sources.sh +++ b/build_tools/check-sources.sh @@ -43,6 +43,12 @@ if [ "$?" != "1" ]; then BAD=1 fi +git grep -Li -E "license|copyright" -- ':*speed*.cc' ':*spdb*.h' ':*speed*.h' ':*spdb*.cc' +if [ "$?" != "1" ]; then + echo '^^^^ Source files do not contain license' + BAD=1 +fi + if [ "$BAD" ]; then exit 1 fi