Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build: npm run watch (experimental) #32866

Merged
merged 1 commit into from
Jul 27, 2023

Commits on Jul 27, 2023

  1. build: npm run watch (experimental)

    Implements the `npm run watch` section of the assets ADR [1], plus some
    modifications since I decided to switch from pywatchman to watchdog (see
    ADR changes for justification). This will replace `paver watch_assets`
    (edx-platform) and `openedx-assets watch-themes` (Tutor).
    
    Specifically, this PR adds three experimental commands:
    
    * `npm run watch-sass` : Watch for Sass changes with watchdog.
    * `npm run watch-webpack` : Invoke Webpack-watch for JS changes.
    * `npm run watch` : Invoke both `watch-sass` and `watch-webpack` simultaneously.
    
    These commands are only intended to work in development mode. They have
    been tested both on bare-metal edx-platform and through `tutor dev run`
    on on Linux.
    
    Before removing the "experimental" label, we need to:
    
    * Test through Devstack on Linux.
    * Test through Devstack and `tutor dev run` on macOS.
    * Test on bare-metal macOS. Might not work, which is OK, but we should
      document that.
    * Document the commands in edx-platform's README.
    * Confirm that this not only works through `tutor dev run`, but also as
      a suitable replacement in the `watchthemes` service that Tutor runs
      automatically as part of `tutor dev start`. Tweak if necessary.
    
    References:
    
    1. https://github.com/openedx/edx-platform/blob/master/docs/decisions/0017-reimplement-asset-processing.rst
    
    Part of: openedx#31612 #
    kdmccormick committed Jul 27, 2023
    Configuration menu
    Copy the full SHA
    c6bc019 View commit details
    Browse the repository at this point in the history