Include header in generated bootstrap files.
This commit is contained in:
+15
-1
@@ -75,6 +75,19 @@ class SymfonyClassCollectionLoader
|
|||||||
{
|
{
|
||||||
static private $loaded;
|
static private $loaded;
|
||||||
|
|
||||||
|
const HEADER = <<<EOS
|
||||||
|
<?php
|
||||||
|
|
||||||
|
/*
|
||||||
|
* This file is part of Mustache.php.
|
||||||
|
*
|
||||||
|
* (c) %d Justin Hileman
|
||||||
|
*
|
||||||
|
* For the full copyright and license information, please view the LICENSE
|
||||||
|
* file that was distributed with this source code.
|
||||||
|
*/
|
||||||
|
EOS;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Loads a list of classes and caches them in one big file.
|
* Loads a list of classes and caches them in one big file.
|
||||||
*
|
*
|
||||||
@@ -105,7 +118,8 @@ class SymfonyClassCollectionLoader
|
|||||||
}
|
}
|
||||||
|
|
||||||
$cache = $cacheDir.'/'.$name.$extension;
|
$cache = $cacheDir.'/'.$name.$extension;
|
||||||
self::writeCacheFile($cache, self::stripComments('<?php '.$content));
|
$header = sprintf(self::HEADER, strftime('%Y'));
|
||||||
|
self::writeCacheFile($cache, $header . substr(self::stripComments('<?php '.$content), 5));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Reference in New Issue
Block a user