•  
      request #14752 Unify scripts and themes build for Core
    Infos
    #14752
    Joris MASSON (jmasson)
    2020-04-10 10:50
    2020-04-02 14:40
    16026
    Details
    Unify scripts and themes build for Core

    This is a follow-up of request #14652

    Now that all plugins have been harmonized, it is time to do the same for Tuleap Core.

    "tuleap/src" should be the "entrypoint" for Tuleap Core. It should contain:

    • package.json & package-lock.json. As long as it makes sense. Some dependencies might still be scoped per-application, as for kanban and planning-v2 in plugins
    • jest.config.js
    • tsconfig.json
    • webpack.(common|dev|prod).js

    This setup will make it easier for everyone to know where they should run "npm" commands. It also lets us unify themes and scripts builds by having only one command to build / watch both.

    We will also take advantage of this big move to change a couple of things:

    1. "Built" scripts should live in "tuleap/src/scripts". They should NOT live in "tuleap/src/www" as they are not meant to be loaded by themselves
    2. "Loaded" standalone (one might say "legacy") scripts should stay in "tuleap/src/www". This layout makes it clear that everything in "www" is supposed to be loaded and is not handled by Webpack
    3. "Core" assets should live in "tuleap/src/www/assets/core". Since they were the first assets, they were assigned to "tuleap/src/www/assets", but following request #14652, all plugins have their equivalent folder here. It's easier for the build script to manage (and delete) its own "core" folder. It's easier for devs who can rely on knowing "everything related to core is in the core folder".
    Dev tools
    Empty
    Empty
    • [ ] enhancement
    • [x] internal improvement
    Empty
    Stage
    Joris MASSON (jmasson)
    Closed
    2020-04-08
    Attachments
    Empty
    References
    Referencing request #14752

    Follow-ups

    User avatar
    Joris MASSON (jmasson)2020-04-08 11:48
    gerrit #18619 (move TLP sources out of www/) integrated into Tuleap 11.13.99.54

    • Status changed from Under review to Closed
    • Close date set to 2020-04-08