]> git.immae.eu Git - github/wallabag/wallabag.git/commitdiff
Add `grunt watch` task
authorJeremy Benoist <jeremy.benoist@gmail.com>
Tue, 8 Nov 2016 21:16:01 +0000 (22:16 +0100)
committerJeremy Benoist <jeremy.benoist@gmail.com>
Tue, 8 Nov 2016 21:16:01 +0000 (22:16 +0100)
Gruntfile.js
package.json

index 72a407f921c9346421a98a219bcce8285103a4c3..72473b21c5d0aced6976698d2641674c381e19e2 100644 (file)
@@ -189,8 +189,11 @@ module.exports = function (grunt) {
     },
     stylelint: {
       target: ['<%= appDir %>/themes/material/css/*.css', '<%= appDir %>/themes/baggy/css/*.css']
+    },
+    watch: {
+      files: ['<%= appDir %>/**/*.css', '<%= appDir %>/**/*.js'],
+      tasks: ['css', 'js']
     }
-
   });
 
   grunt.registerTask(
@@ -221,5 +224,7 @@ module.exports = function (grunt) {
       'tests',
       'Test css and js style conformity',
       ['eslint', 'stylelint', 'default']
-  )
+  ),
+
+  grunt.loadNpmTasks('grunt-contrib-watch');
 };
index 20afb4259383f6150131d5d55b69c7b1da5c349c..ace74c7f80db0528a6e2aeda9d47ab9e8ab556e0 100644 (file)
@@ -77,6 +77,7 @@
     "grunt-contrib-copy": "^1.0.0",
     "grunt-contrib-symlink": "^1.0.0",
     "grunt-contrib-uglify": "^1.0.0",
+    "grunt-contrib-watch": "^1.0.0",
     "grunt-eslint": "^19.0.0",
     "grunt-postcss": "^0.8.0",
     "grunt-stylelint": "^0.6.0",