Make autoloader suffix a reproducible value as well, refs #3927
parent
164dc2a097
commit
2a48b0faa0
|
@ -3,9 +3,16 @@
|
|||
|
||||
$cwd = getcwd();
|
||||
chdir(__DIR__.'/../');
|
||||
$ts = rtrim(shell_exec('git log -n1 --pretty=%ct HEAD'));
|
||||
if (!is_numeric($ts)) {
|
||||
echo 'Could not detect date using "git log -n1 --pretty=%ct HEAD"'.PHP_EOL;
|
||||
exit(1);
|
||||
}
|
||||
// Install with the current version to force it having the right ClassLoader version
|
||||
// Install without dev packages to clean up the included classmap from phpunit classes
|
||||
shell_exec('php bin/composer config autoloader-suffix ComposerPhar' . $ts);
|
||||
shell_exec('php bin/composer install -q --no-dev');
|
||||
shell_exec('php bin/composer config autoloader-suffix --unset');
|
||||
chdir($cwd);
|
||||
|
||||
require __DIR__.'/../src/bootstrap.php';
|
||||
|
|
|
@ -145,7 +145,7 @@ class Compiler
|
|||
|
||||
unset($phar);
|
||||
|
||||
// resign the phar with reproducible timestamp / signature
|
||||
// re-sign the phar with reproducible timestamp / signature
|
||||
$util = new Timestamps($pharFile);
|
||||
$util->updateTimestamps($this->versionDate);
|
||||
$util->save($pharFile, \Phar::SHA1);
|
||||
|
|
Loading…
Reference in New Issue