View Full Version : how to compile this application with cmd

4 Nov 2012, 2:45 PM

im using codeigniter and extjs 4.1.1a to build the app and my project is located in apache/php server i access it like

inside my index i have these javascripts

<script type="text/javascript" src="<?=base_url()?>extjs/ext-all.js"></script>
<script type="text/javascript" src="<?=base_url()?>template/overrides.js"></script>

<script type="text/javascript" src="<?=base_url()?>app/app.js"></script>
<script type="text/javascript" src="<?=base_url()?>api/configData"></script>//for ext direct

my question is how to use sencha cmd to build application located in a server like this? how to point app location to ?


6 Nov 2012, 11:02 AM
In a nutshell, Sencha Cmd operates on source files, so it will need to be run against the source code instead of a served instance.

For script tags, the src attributes need to use relative addressing (relative to the markup file) for Sencha Cmd to resolve the address and combine them in to a build. This should be workable in production as well, but obviously takes some adjustments perhaps.

There are some lower-level ways to deal with just JS files, but to use the high-level "page" command of the compiler, the above is required. To go the lower-level route, you would still need file system access to the JS source tree(s) and would need to identify the script(s) that serve as the "top" of the dependency calculation (the page serves that role when using the "page" command).

6 Nov 2012, 11:06 AM
yup. i did the necessary changes and got the project out from server to build with CMD