File: check_copyright.sh

package info (click to toggle)
libdmtx 0.7.8-1
  • links: PTS
  • area: main
  • in suites: forky, sid
  • size: 2,108 kB
  • sloc: ansic: 10,638; sh: 253; makefile: 154; perl: 28
file content (12 lines) | stat: -rwxr-xr-x 224 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
#!/bin/sh

FILE="$1"

# Every nontrivial source file must include a copyright line
COPYRIGHT=$(grep "Copyright 2[[:digit:]]\{3\}" $FILE)
if [[ $? -ne 0 ]]; then
   echo "Missing copyright text in $FILE"
   exit 1
fi

exit 0