diff --git a/CommonChickenRuntimeEngine/src/ccre/testing/TestFiles.java b/CommonChickenRuntimeEngine/src/ccre/testing/TestFiles.java index d654ef49..edf748c9 100644 --- a/CommonChickenRuntimeEngine/src/ccre/testing/TestFiles.java +++ b/CommonChickenRuntimeEngine/src/ccre/testing/TestFiles.java @@ -1,3 +1,25 @@ +/* + * Copyright 2015 Colby Skeggs + * + * This file is part of the CCRE, the Common Chicken Runtime Engine. + * + * The CCRE is free software: you can redistribute it and/or modify it under the + * terms of the GNU Lesser General Public License as published by the Free + * Software Foundation, either version 3 of the License, or (at your option) any + * later version. + * + * The CCRE is distributed in the hope that it will be useful, but WITHOUT ANY + * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR + * A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more + * details. + * + * You should have received a copy of the GNU Lesser General Public License + * along with the CCRE. If not, see . + * + * + * This file contains code inspired by/based on code Copyright 2008-2014 FIRST. + * To see the license terms of that code (modified BSD), see the root of the CCRE. + */ package ccre.testing; import java.io.IOException; diff --git a/check-headers.sh b/check-headers.sh new file mode 100755 index 00000000..5e5fa0c1 --- /dev/null +++ b/check-headers.sh @@ -0,0 +1,30 @@ +echo +echo Enumerating files... +echo +GOOD=true +for x in `find -name '*.java'` +do + if head -n 18 $x | grep -iE '(This file is part of the CCRE, the Common Chicken Runtime Engine[.]|Copyright \(c\) FIRST)' >/dev/null + then + true + else + if echo $x | grep -iE '(SampleIgneousRobot|cobertura|TemplateIgneousRobot)' >/dev/null + then + true + else + echo $x BAD + GOOD=false + fi + fi +done +echo +if $GOOD +then + echo Done enumerating. All files pass inspection. + echo + exit 0 +else + echo Done enumerating. Not ready to commit. You forgot some license headers! + echo + exit 1 +fi