clean.js 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. /**
  2. * `tasks/config/clean`
  3. *
  4. * ---------------------------------------------------------------
  5. *
  6. * Remove the files and folders in your Sails app's web root
  7. * (conventionally a hidden directory called `.tmp/public`).
  8. *
  9. * For more information, see:
  10. * https://sailsjs.com/anatomy/tasks/config/clean.js
  11. *
  12. */
  13. module.exports = function(grunt) {
  14. grunt.config.set('clean', {
  15. dev: ['.tmp/public/**'],
  16. build: ['www']
  17. });
  18. // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  19. // This Grunt plugin is part of the default asset pipeline in Sails,
  20. // so it's already been automatically loaded for you at this point.
  21. //
  22. // Of course, you can always remove this Grunt plugin altogether by
  23. // deleting this file. But check this out: you can also use your
  24. // _own_ custom version of this Grunt plugin.
  25. //
  26. // Here's how:
  27. //
  28. // 1. Install it as a local dependency of your Sails app:
  29. // ```
  30. // $ npm install grunt-contrib-clean --save-dev --save-exact
  31. // ```
  32. //
  33. //
  34. // 2. Then uncomment the following code:
  35. //
  36. // ```
  37. // // Load Grunt plugin from the node_modules/ folder.
  38. // grunt.loadNpmTasks('grunt-contrib-clean');
  39. // ```
  40. // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  41. };