Skip to content

Commit eae5c45

Browse files
author
Karpenko, Oleksandr
committed
MAGETWO-56915: Versioning of static files (CSS, JS, Fonts, Images, etc.) doesn't enabled by default - for mainline
1 parent 5197f28 commit eae5c45

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

app/code/Magento/Deploy/Model/Deployer.php

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -215,6 +215,9 @@ public function deploy(ObjectManagerFactory $omFactory, array $locales, array $d
215215
$libFiles = $this->filesUtil->getStaticLibraryFiles();
216216
$appFiles = $this->filesUtil->getStaticPreProcessingFiles();
217217

218+
$version = (new \DateTime())->getTimestamp();
219+
$this->versionStorage->save($version);
220+
218221
foreach ($deployableAreaThemeMap as $area => $themes) {
219222
$this->emulateApplicationArea($area);
220223
foreach ($locales as $locale) {
@@ -319,11 +322,7 @@ public function deploy(ObjectManagerFactory $omFactory, array $locales, array $d
319322
$this->output->writeln("\nSuccessful: {$this->count} files modified\n---\n");
320323
}
321324

322-
$version = (new \DateTime())->getTimestamp();
323325
$this->output->writeln("New version of deployed files: {$version}");
324-
if (!$this->getOption(Options::DRY_RUN)) {
325-
$this->versionStorage->save($version);
326-
}
327326

328327
if ($this->errorCount > 0) {
329328
// we must have an exit code higher than zero to indicate something was wrong

0 commit comments

Comments
 (0)