mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2025-10-16 12:05:38 +00:00
Build Tools: Avoid doing copy:dynamic when running grunt watch when using --dev option.
This prevents erroneously copying a file from source onto itself in source. Props westonruter, jorbin. Fixes #59196. git-svn-id: https://develop.svn.wordpress.org/trunk@56461 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
dfda67a587
commit
f085426605
@ -1798,8 +1798,10 @@ module.exports = function(grunt) {
|
||||
// Clean up only those files that were deleted.
|
||||
grunt.config( [ 'clean', 'dynamic', 'src' ], src );
|
||||
} else {
|
||||
// Otherwise copy over only the changed file.
|
||||
grunt.config( [ 'copy', 'dynamic', 'src' ], src );
|
||||
if ( ! grunt.option( 'dev' ) ) {
|
||||
// Otherwise copy over only the changed file.
|
||||
grunt.config(['copy', 'dynamic', 'src'], src);
|
||||
}
|
||||
|
||||
// For javascript also minify and validate the changed file.
|
||||
if ( target === 'js-enqueues' ) {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user