Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-68610

grunt watch does not work on windows without watchman

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open
    • Priority: Minor
    • Resolution: Unresolved
    • Affects Version/s: 3.8.2
    • Fix Version/s: None
    • Component/s: JavaScript
    • Labels:
      None
    • Affected Branches:
      MOODLE_38_STABLE

      Description

      When running for example grunt watch --root=question/types/ddimageortext -v task on windows to watch for any changes without Watchman installed the watch task is watching only css files but in whole moodle installation, not just in the component. If the same command is run with watchman installed everything works as expected.
      I suspect root parameter is not passed correctly to the watch task.
      This is the output of the above command from the latest stable_master

      C:\Users\Martin\moodles\stable_master\moodle>grunt watch --root=question/type/ddimageortext -v
      Initializing
      Command-line options: --root=question/type/ddimageortext, --verbose
       
      Reading "Gruntfile.js" Gruntfile...OK
       
      Registering Gruntfile tasks.
      Reading package.json...OK
      Parsing package.json...OK
      >> Setting root to C:\Users\Martin\moodles\stable_master\moodle\question\type\ddimageortext
      >> Running tasks for component directory question/type/ddimageortext
      Initializing config...OK
       
      Registering "grunt-contrib-uglify" local Npm module tasks.
      Reading C:\Users\Martin\moodles\stable_master\moodle\node_modules\grunt-contrib-uglify\package.json...OK
      Parsing C:\Users\Martin\moodles\stable_master\moodle\node_modules\grunt-contrib-uglify\package.json...OK
      Loading "uglify.js" tasks...OK
      + uglify
       
      Registering "grunt-contrib-watch" local Npm module tasks.
      Reading C:\Users\Martin\moodles\stable_master\moodle\node_modules\grunt-contrib-watch\package.json...OK
      Parsing C:\Users\Martin\moodles\stable_master\moodle\node_modules\grunt-contrib-watch\package.json...OK
      Loading "watch.js" tasks...OK
      + watch
       
      Registering "grunt-sass" local Npm module tasks.
      Reading C:\Users\Martin\moodles\stable_master\moodle\node_modules\grunt-sass\package.json...OK
      Parsing C:\Users\Martin\moodles\stable_master\moodle\node_modules\grunt-sass\package.json...OK
       
      node-sass       4.11.0  (Wrapper)       [JavaScript]
      libsass         3.5.4   (Sass Compiler) [C/C++]
       
      Loading "sass.js" tasks...OK
      + sass
       
      Registering "grunt-eslint" local Npm module tasks.
      Reading C:\Users\Martin\moodles\stable_master\moodle\node_modules\grunt-eslint\package.json...OK
      Parsing C:\Users\Martin\moodles\stable_master\moodle\node_modules\grunt-eslint\package.json...OK
      Loading "eslint.js" tasks...OK
      + eslint
       
      Registering "grunt-stylelint" local Npm module tasks.
      Reading C:\Users\Martin\moodles\stable_master\moodle\node_modules\grunt-stylelint\package.json...OK
      Parsing C:\Users\Martin\moodles\stable_master\moodle\node_modules\grunt-stylelint\package.json...OK
      Loading "grunt-stylelint.js" tasks...OK
      + stylelint
       
      Registering "grunt-babel" local Npm module tasks.
      Reading C:\Users\Martin\moodles\stable_master\moodle\node_modules\grunt-babel\package.json...OK
      Parsing C:\Users\Martin\moodles\stable_master\moodle\node_modules\grunt-babel\package.json...OK
      Loading "babel.js" tasks...OK
      + babel
      Loading "Gruntfile.js" tasks...OK
      - watch
      + amd, css, default, gherkinlint, ignorefiles, js, rawcss, scss, shifter, startup, watch, watch-grunt, yui
       
      Running tasks: watch
       
      Running "watch" task
      Watchman:  Watchman was not found in PATH.  See https://facebook.github.io/watchman/docs/install.html for installation instructions
      >> It is recommended that you install Watchman for better performance using the "watch" command.
       
      Running "watch" task
      Waiting...
      Verifying property watch exists in config...OK
      Verifying property watch.amd.files exists in config...OK
      Verifying property watch.boost.files exists in config...OK
      Verifying property watch.rawcss.files exists in config...OK
      Verifying property watch.yui.files exists in config...OK
      Verifying property watch.gherkinlint.files exists in config...OK
      Watching admin\tool\behat\styles.css for changes.
      Watching admin\tool\behat\classes for changes.
      Watching admin\tool\behat\cli for changes.
      Watching admin\tool\behat\lang for changes.
      Watching admin\tool\behat\tests for changes.
      Watching admin\tool\capability\styles.css for changes.
      Watching admin\tool\capability\classes for changes.
      Watching admin\tool\capability\lang for changes.
      Watching admin\tool\capability\tests for changes.
      Watching admin\tool\capability\yui for changes.
      Watching admin\tool\dataprivacy\styles.css for changes.
      Watching admin\tool\dataprivacy\amd for changes.
      Watching admin\tool\dataprivacy\classes for changes.
      Watching admin\tool\dataprivacy\db for changes.
      Watching admin\tool\dataprivacy\lang for changes.
      Watching admin\tool\dataprivacy\templates for changes.
      Watching admin\tool\dataprivacy\tests for changes.
      Watching admin\tool\filetypes\styles.css for changes.
      Watching admin\tool\filetypes\classes for changes.
      Watching admin\tool\filetypes\lang for changes.
      Watching admin\tool\filetypes\tests for changes.
      Watching admin\tool\health\styles.css for changes.
      Watching admin\tool\health\classes for changes.
      Watching admin\tool\health\lang for changes.
      Watching admin\tool\health\tests for changes.
      Watching admin\tool\installaddon\styles.css for changes.
      Watching admin\tool\installaddon\classes for changes.
      Watching admin\tool\installaddon\lang for changes.
      Watching admin\tool\installaddon\pix for changes.
      Watching admin\tool\installaddon\tests for changes.
      Watching admin\tool\installaddon\yui for changes.
      Watching admin\tool\langimport\styles.css for changes.
      Watching admin\tool\langimport\classes for changes.
      Watching admin\tool\langimport\db for changes.
      Watching admin\tool\langimport\lang for changes.
      Watching admin\tool\langimport\templates for changes.
      Watching admin\tool\langimport\tests for changes.
      Watching admin\tool\lp\styles.css for changes.
      Watching admin\tool\lp\amd for changes.
      Watching admin\tool\lp\classes for changes.
      Watching admin\tool\lp\db for changes.
      Watching admin\tool\lp\lang for changes.
      Watching admin\tool\lp\pix for changes.
      Watching admin\tool\lp\templates for changes.
      Watching admin\tool\lp\tests for changes.
      Watching admin\tool\lp\yui for changes.
      Watching admin\tool\messageinbound\styles.css for changes.
      Watching admin\tool\messageinbound\classes for changes.
      Watching admin\tool\messageinbound\db for changes.
      Watching admin\tool\messageinbound\lang for changes.
      Watching admin\tool\messageinbound\tests for changes.
      Watching admin\tool\policy\styles.css for changes.
      Watching admin\tool\policy\amd for changes.
      Watching admin\tool\policy\classes for changes.
      Watching admin\tool\policy\db for changes.
      Watching admin\tool\policy\lang for changes.
      Watching admin\tool\policy\pix for changes.
      Watching admin\tool\policy\templates for changes.
      Watching admin\tool\policy\tests for changes.
      Watching admin\tool\profiling\styles.css for changes.
      Watching admin\tool\profiling\classes for changes.
      Watching admin\tool\profiling\lang for changes.
      Watching admin\tool\task\styles.css for changes.
      Watching admin\tool\task\classes for changes.
      Watching admin\tool\task\cli for changes.
      Watching admin\tool\task\lang for changes.
      Watching admin\tool\task\templates for changes.
      Watching admin\tool\task\tests for changes.
      Watching admin\tool\templatelibrary\styles.css for changes.
      Watching admin\tool\templatelibrary\amd for changes.
      Watching admin\tool\templatelibrary\classes for changes.
      Watching admin\tool\templatelibrary\db for changes.
      Watching admin\tool\templatelibrary\lang for changes.
      Watching admin\tool\templatelibrary\templates for changes.
      Watching admin\tool\templatelibrary\tests for changes.
      Watching admin\tool\usertours\styles.css for changes.
      Watching admin\tool\usertours\amd for changes.
      Watching admin\tool\usertours\classes for changes.
      Watching admin\tool\usertours\db for changes.
      Watching admin\tool\usertours\lang for changes.
      Watching admin\tool\usertours\pix for changes.
      Watching admin\tool\usertours\templates for changes.
      Watching admin\tool\usertours\tests for changes.
      Watching admin\tool\usertours\tours for changes.
      Watching admin\tool\xmldb\styles_boost.css for changes.
      Watching admin\tool\xmldb\styles_bootstrapbase.css for changes.
      Watching admin\tool\xmldb\actions for changes.
      Watching admin\tool\xmldb\amd for changes.
      Watching admin\tool\xmldb\classes for changes.
      Watching admin\tool\xmldb\db for changes.
      Watching admin\tool\xmldb\lang for changes.
      Watching admin\tool\xmldb\tests for changes.
      ...
      

        Attachments

          Activity

            People

            Assignee:
            Unassigned Unassigned
            Reporter:
            mastnym Martin Mastny
            Participants:
            Component watchers:
            Andrew Lyons, Dongsheng Cai, Huong Nguyen, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated: