Ext: 6.0.1
CMD: 6.0.2.14


Hello,


We are in a scenario where we need to generate multiple theme based css files in production. Our css themes rarely change and due to the size of our app we would rather compile the css at a seperate time then when we run the javascript build. I am aware of the builds property for app.json, but the main problem is we do not want to recompile all the javascripts and css for each theme in the builds property. Especially since the javascript does not change for each theme and the main difference will be what app.json file is loaded and the correct path to the css. Here is one approach I have tried:


Code:
"builds": {
    "classic": {
        "toolkit": "classic",
        "theme": "theme-soho-base",
        "output": {
           "js": {
               "optimize": {
                   "defines": false,
                   "callParent": false,
                   "requires": false
                }
           }
        }
    },
    "dark": {
        "toolkit": "classic",
        "theme": "theme-soho-dark",
        "output": {
            "manifest": "${build.id}.json",
            "resources": "resources/${build.id}",
            "js": {
               "enable": false,
               "optimize": {
                   "defines": false,
                   "callParent": false,
                   "requires": false
                }
           }
        }
    }
}

This will generate the css into the proper folders and create the correct app.json based on the profile name.


Example output:


/build/production/MYAPP/dark.json
/build/production/MYAPP/classic.json
/build/production/MYAPP/resource/dark/MYALL_all.css
/build/production/MYAPP/resource/classic/MYALL_all.css


Here is the exact process we would like to do for production:


1.) CSS developer compiles themes and checks in the css file to a resource folder.
2.) The build machine compiles just the javascripts and specified app.json (dark.json, foo.json) files.
3.) (Known part) The non-javascrpit build process would check out the css and copy it to the final production location.
3.) (Known part) The non-javascrpit build process would copy the javascripts and manifest to the final production location.


I have also read the following post and the links associated to it. It is close, but not exactly what we want to do.


https://www.sencha.com/forum/showthread.php?298264


Is it possible to do this the way we want? Are we doing the right approach?


Thanks,


Bryan