Skip to content

Commit 27fd131

Browse files
committed
Added a license to the license-adding script
1 parent 4be36a1 commit 27fd131

File tree

1 file changed

+34
-1
lines changed

1 file changed

+34
-1
lines changed

ClassixHeader.php

Lines changed: 34 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,33 @@
11
<?php
2+
//
3+
// ClassixHeader.php
4+
//
5+
// Copyright (C) 2012 Félix Cloutier
6+
//
7+
// This file is distributed with the Classix project source but is licensed
8+
// separately under the following terms:
9+
//
10+
// Permission is hereby granted, free of charge, to any person obtaining a copy
11+
// of this software and associated documentation files (the "Software"), to deal
12+
// in the Software without restriction, including without limitation the rights
13+
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
14+
// copies of the Software, and to permit persons to whom the Software is
15+
// furnished to do so, subject to the following conditions:
16+
//
17+
// The above copyright notice and this permission notice shall be included in
18+
// all copies or substantial portions of the Software.
19+
//
20+
// ClassixHeader.php IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
21+
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
22+
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
23+
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
24+
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
25+
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
26+
// THE SOFTWARE.
27+
//
28+
29+
// (How ironic is it that a PHP script that adds the GPL license header is
30+
// itself licensed under the MIT license.)
231

332
function recursiveFileList($extensions, $dirPath = ".")
433
{
@@ -66,7 +95,11 @@ function makeHeader($file, $project, $author, $year)
6695
unset($file[$i]);
6796
}
6897

69-
$header = makeHeader(basename($codeFile), "Classix", "Félix Cloutier", 2012);
98+
$projectName = "Classix";
99+
$author = "Félix Cloutier";
100+
$year = 2012;
101+
102+
$header = makeHeader(basename($codeFile), $projectName, $author, $year);
70103
file_put_contents($codeFile, $header . join("", $file));
71104
}
72105

0 commit comments

Comments
 (0)