WordPress.org

Make WordPress Core

Opened 5 years ago

Last modified 6 months ago

#29066 new defect (bug)

Grunt clean:dynamic task does not delete file/s from /build during grunt watch task

Reported by: netweb Owned by:
Milestone: Awaiting Review Priority: normal
Severity: minor Version: 3.7
Component: Build/Test Tools Keywords: needs-patch
Focuses: Cc:

Description

When running the Grunt task grunt watch a file that is modified and saved should be cleaned from the /build folder and the modified file copied from the /src folder to the /build folder as part of the watch:all task:

tasks: [ 'clean:dynamic', 'copy:dynamic' ],

Currently the clean:dynamic task does not actually 'clean' (delete) the file from the /build folder, the copy:dynamic task overwrites the existing file.

Workaround: Do nothing and continue to have the file overwritten without cleaning first.

Options:

  1. Fix the clean:dynamic task to actually 'clean' (delete) the file from /build
  1. Remove the clean:dynamic task from the clean and watch:all tasks list

To reproduce:

  • Temporarilly remove copy:dynamic from the watch:all task tasks list
  • Run grunt watch
  • Edit a file from /src and save

Expected Results:

  • Edited file should be 'cleaned' (deleted) in /build folder

Actual results:

  • File remains in /build folder

Change History (2)

#1 @netweb
5 years ago

  • Severity changed from normal to minor

#2 @chriscct7
4 years ago

  • Keywords needs-patch added
Note: See TracTickets for help on using tickets.