don't export templates and scss files
This commit is contained in:
parent
b513f88328
commit
afb04ef056
@ -43,14 +43,22 @@ class GeneratorHelper
|
|||||||
throw new RuntimeException("Cannot copy '$source' to '$destination'");
|
throw new RuntimeException("Cannot copy '$source' to '$destination'");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$aExclDirs = array(
|
||||||
|
'scss',
|
||||||
|
'templates'
|
||||||
|
);
|
||||||
|
$aExclFiles = array(
|
||||||
|
'config.json'
|
||||||
|
);
|
||||||
|
|
||||||
while (false !== ($file = readdir($dir))) {
|
while (false !== ($file = readdir($dir))) {
|
||||||
if ($file != '.' && $file != '..') {
|
if ($file != '.' && $file != '..') {
|
||||||
if (is_dir($source . DIRECTORY_SEPARATOR . $file)) {
|
if (is_dir($source . DIRECTORY_SEPARATOR . $file) && false == in_array($file, $aExclDirs)) {
|
||||||
static::copyRecursive(
|
static::copyRecursive(
|
||||||
$source . DIRECTORY_SEPARATOR . $file,
|
$source . DIRECTORY_SEPARATOR . $file,
|
||||||
$destination . DIRECTORY_SEPARATOR . $file
|
$destination . DIRECTORY_SEPARATOR . $file
|
||||||
);
|
);
|
||||||
} else {
|
} elseif (false == in_array($file, $aExclFiles)) {
|
||||||
copy($source . DIRECTORY_SEPARATOR . $file, $destination . DIRECTORY_SEPARATOR . $file);
|
copy($source . DIRECTORY_SEPARATOR . $file, $destination . DIRECTORY_SEPARATOR . $file);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user