10 May 2012 6:00 AM #1
Sencha SDK Tools 2.0 and ExtJS4: The Missing Docs
I just completed a very frustrating few days of work with the Sencha SDK Tools in order to get it to work in a consistent and reliable way for my medium-sized ExtJS4 project.
My requirements were:
- The build must be 100% reliable. It cannot fail 25% of the time like the current SDK Tools do.
- It must run on a build server.
- It must update automatically - adding components to my application must not break the build.
- The build must include the smallest working subset of ExtJS.
I have modified some of the SDK Tools source to make this happen. I created a comprehensive guide on how to use the SDK Tools including this modified source. Please take a look if your project is anything like mine.
Please post any thoughts/problems/ideas/code.
14 May 2012 11:24 AM #2
I've been seeing a lot of views on the doc, but no comments. Please let me know how it has been going!
15 May 2012 5:10 AM #3
it's working very well now. Your fix to phantom.js did the trick. Now it's useable. At least for me.
Thank you very much.
17 May 2012 6:46 AM #4
Thanks, Thorsten. I've been discussing the possibility of including these changes in Beta4 with Sencha. Stay tuned.
19 May 2012 6:11 AM #5
I cried when I found this. Thank you. I had given up with sencha and was trolling for tools...
Smart boy you. Wish I could have figured that out.
index-build is required to have the .html extension
my.site.com fails but mysite.com/ produces a jsb3
After two days of terror I can back to working out a deployment cycle. Yes!
* * *
There's one other area sencha has assumed everyone knows and understands, and that is the project directory structure. A real one, not a demo. Languages, sites, subdomains, projects, components, apps, sub-apps, builds, themes, libs, ux...
I developed something I thought was following their pattern, but the build tools and SA are proving me wrong.
Looks like maybe you have that one nailed too.
19 May 2012 12:51 PM #6
Thanks for the warm words, stewardsencha.
As for directory structure, I have been making it up as I go, starting from the default directory structure given by Architect.
My ExtJS4 project structure:
/app - all app files (e.g. '/app/controller', '/app/model', etc.) /build - all build files, such as app-all.js, all-classes.js, etc. /lib - all third party files, some in subfolders for organization /extensions - all extjs overrides or extensions /extjs - extjs builds /src - extjs source files /metadata - created by Architect /resources /fonts - web fonts /images /sass - I use compass, so all .scss files and builds go here. /statics - static html files for my project /support - Jenkins(Continuous Integration) files /tests
All index-(build | test | dev | prod) files are in root, along with my-project.jsb3 and some Architect files.
That's been working out well for me for now.
24 May 2012 8:20 AM #7
comments on the gdoc itself don't seem to stickPhil Strong
24 May 2012 7:47 PM #8
25 May 2012 3:01 AM #9
Hey Phil - comments seem to stick in incognito for me. Maybe try again?
Abcoa - by 'resources', you mean JS files, right? Make sure you're running the updated phantom-jsb.js from the top of the doc. I had some problems with the actual building of the JSB3. However, if you mean that your JSB3 is built and you are not getting any output, I would triple-check your paths and run sencha build with the -v parameter.
Paths in a JSB3 require a tailing '/' which trips some people up. Running in verbose mode should tell you which paths have failed.
25 May 2012 5:08 AM #10
I'm trying to follow your instruction and I've put ext-dev.js instead of ext-debug.js.
I get these errors:
$ sencha create jsb -a index-build.html -p app.jsb3 -v
[E] Failed loading 'src/app/Application.js', please verify that the file exists
Failed loading 'src/app/Application.js', please verify that the file exists
file:////media/Podaci/web/ks/lib/ext-4.0/ext-dev.js : 8712
file:////media/Podaci/web/ks/lib/ext-4.0/ext-dev.js : 8216
file:////media/Podaci/web/ks/lib/ext-4.0/ext-dev.js : 2454
file:////media/Podaci/web/ks/lib/ext-4.0/ext-dev.js : 7943
file:////media/Podaci/web/ks/lib/ext-4.0/ext-dev.js : 7892
This happens with original and with your phantom file so this is caused by ext-dev. Any idea why?
If I use ext-debug I don't see these errors.