blob: d05e99aa90ef0f28fadf388fc47fb23656065117 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
# file : tests/git-pre-commit-copyright-check.testscript
# license : MIT; see accompanying LICENSE file
.include git-common.testscript git-pre-commit-common.testscript
: basic
:
{
$clone_prj;
cat <<EOI >=prj/LICENSE;
Copyright (c) 2014-2019 the build2 authors.
EOI
$ga .;
$gc 2>>~%EOE%;
%.+WARNING:.+ last copyright year in 'LICENSE' is 2019%
EOE
date +"%Y" | set year;
cat <<"EOI" >=prj/LICENSE;
Copyright (c) 2014-$year the build2 authors.
EOI
$gc
}
|