Skip to content

Commit

Permalink
An explicit chmod() call is needed to set the file mode
Browse files Browse the repository at this point in the history
  • Loading branch information
Ocramius committed Dec 30, 2016
1 parent 486ebd8 commit faf066e
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions src/PackageVersions/Installer.php
Original file line number Diff line number Diff line change
Expand Up @@ -124,12 +124,11 @@ private static function writeVersionClassToFile(
Config $composerConfig,
RootPackageInterface $rootPackage
) {
file_put_contents(
self::locateRootPackageInstallPath($composerConfig, $rootPackage)
. '/src/PackageVersions/Versions.php',
$versionClassSource,
0664
);
$installPath = self::locateRootPackageInstallPath($composerConfig, $rootPackage)
. '/src/PackageVersions/Versions.php';

file_put_contents($installPath, $versionClassSource, 0664);
chmod($installPath, 0664);
}

/**
Expand Down

0 comments on commit faf066e

Please sign in to comment.