-
12 Mar 2013 4:48 AM #1
sencha sdk -> cmd
sencha sdk -> cmd
hi,
i am facing issues by running something like this at the moment. It looks sencha sdk is just hanging on OSX, never comes back. Any idea?
It that reason I thought it is time to move to Cmd v3 as using 4.1.x for my projects. But could not find "sencha create" with cmd v3. What is the syntax for it?Code:sencha create jsb -a http://localhost:9002/development.html -p /Users/vuukie/Workspaces/cafe4/src/main/webapp/app.jsb3
thx,
Zol
-
14 Mar 2013 10:25 AM #2Sencha - Senior Forum Manager
- Join Date
- Mar 2007
- Location
- St. Louis, MO
- Posts
- 33,624
- Vote Rating
- 434
Cmd doesn't use jsb files. Just need to build the app and it will figure out the dependencies based on the requires and other factors.
Mitchell Simoens @SenchaMitch
Sencha Inc, Senior Forum Manager
________________
http://www.JSONPLint.com - Source to lint your JSONP!
Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
https://github.com/mitchellsimoens
Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/
Need more help with your app? Hire Sencha Services services@sencha.com
Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is almost in print!
When posting code, please use BBCode's CODE tags.
-
15 Apr 2013 11:23 PM #3
hi,
I am bit confused with your answer. The documentation is about to wait till using cmd. http://docs.sencha.com/extjs/4.1.3/#!/guide/command
It says:In my case project is 4.1.3, can I make the whole built procedure with cmd v3? (in other words: Can I deprecate sdk tools? Both sdk-tool and cmd v3 is not working on the same os x imac).Sencha Cmd is designed for Sencha Ext JS version 4.1.1a or higher and Sencha Touch version 2.1 or higher. Many of the new features of Sencha Cmd require framework support that is only available at these version levels. There are some low-level commands that can be used for older versions of Sencha frameworks or JavaScript in general.
If you are using an older version of Ext JS, you may use Sencha Cmd's build command to build via your JSB file. In other words, Sencha Cmd can replace JSBuilder to produce a compressed build of the files described in a JSB file. Sencha Cmd will not update your JSB file as was done by the previous SDK Tools v2. If your build process requires this support, then you should wait to upgrade to Sencha Cmd.
Can you give me a simple example how to use cmd v3 to create app-all.js ?
thx,
Zol
-
16 Apr 2013 5:12 AM #4Sencha - Senior Forum Manager
- Join Date
- Mar 2007
- Location
- St. Louis, MO
- Posts
- 33,624
- Vote Rating
- 434
4.1.3 should use Cmd. The documentation was updated and will work if you look at the docs for 4.2.0:
http://docs.sencha.com/extjs/4.2.0/#!/guide/commandMitchell Simoens @SenchaMitch
Sencha Inc, Senior Forum Manager
________________
http://www.JSONPLint.com - Source to lint your JSONP!
Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
https://github.com/mitchellsimoens
Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/
Need more help with your app? Hire Sencha Services services@sencha.com
Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is almost in print!
When posting code, please use BBCode's CODE tags.
-
16 Apr 2013 6:42 AM #5
thanks Mitchell, I have read thru that links, and also advanced cmd page, also checked comments. Ant other also confused with 'build', does it, or does not need jsb3?
This was my old SDK-Tool based command to minimize my js (encapsulated into a maven build):
And this commmand made app-all.js just fine. The jsb3 was generated like this:Code:sencha build -p /Users/me/prjname/src/name/webapp/apps.jsb3 -d /Users/me/prjname/src/main/webapp -v
So, you say no jsb3 needs at all. I have tried many things, but still not sure what to do, and how to give the entry point to cmd. My app.js is under /Users/me/prjname/src/main/webapp/app.js, and I am looking for a compressed output in the same folder (or anywhere) just called app-all.js.Code:sencha create jsb -a /Users/me/prjname/src/main/webapp/indexjsb3.html -p /Users/me/src/main/webapp/app.jsb3 -v
In the documentation that simply task is missing.
is tellingCode:sencha help build
Do I need a jsb3 file, or not?This command is used to process a legacy JSBuilder ("jsb") file.
What is the "category" for sencha cmd to make this. I have also tried to do sencha compile concatenate... No luck at all.
The most promising attempt was:
as this having a flag as destination.Code:sencha help app build
But let me start, and maybe you can correct me how to do this with cmd 3.1.0:
Flag -d (debug) and -v (verbose) is available?Code:sencha app build -a /Users/me/prjname/src/main/webapp/indexjsb3.html -d /Users/me/src/main/webapp
thx
-
16 Apr 2013 6:58 AM #6Sencha - Senior Forum Manager
- Join Date
- Mar 2007
- Location
- St. Louis, MO
- Posts
- 33,624
- Vote Rating
- 434
A quick run down of useful commands.
To create an application with Cmd you do:
This will create a skeleton app that you can then copy your application in to to "upgrade" it from your old app to a Cmd application.Code:sencha generate app MyApp /path/to/MyApp
Once in a Cmd application you can then use this command to do a build:
This will create a production build, to do a testing build you can doCode:sencha app build
This does not use a jsb file anymore, it will go through your code and evaluate the requires properties (stores, models, etc).Code:sencha app build testing
Mitchell Simoens @SenchaMitch
Sencha Inc, Senior Forum Manager
________________
http://www.JSONPLint.com - Source to lint your JSONP!
Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
https://github.com/mitchellsimoens
Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/
Need more help with your app? Hire Sencha Services services@sencha.com
Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is almost in print!
When posting code, please use BBCode's CODE tags.
-
16 Apr 2013 7:29 AM #7
hi,
app generated like this:
Do I need the whole lot from this structure? The only two makes sense me are:Code:sencha -s /Users/me/extjs-4.1.3/ generate app MyApp /Users/me/MyApp
- app
- ext
Probably other two folders also not hurt:
- packages
- resources
But what about bootstrap.js, build.xml? What are these files?
And what do you suggest for me, what is best practice to weave in my existing structure (cvs stored project), I need to add MyApp such as webapp but not in root level, just as src/main/webapp/. Will that work if I move some files?
Currently I have in my src/main/webapp these things:
- app.js
- ext folder
- app folder (mvc)
thx a lot
-
17 Apr 2013 4:54 AM #8
hi, almost there.
How can I set to target folder where to write all.js?
Code:sencha -cw /Users/me/Workspaces/MyPrj/src/main/webapp app build -d /Users/me/Workspaces/MyPrj/src/main/webapp
this writes into:
thx[INF] Concatenating output to file /Users/me/Workspaces/MyPrj/src/main/webapp/build/MyApp/production/all-classes.js
ps: app-all.js not made any longer?
-
17 Apr 2013 5:29 AM #9Sencha - Senior Forum Manager
- Join Date
- Mar 2007
- Location
- St. Louis, MO
- Posts
- 33,624
- Vote Rating
- 434
Mitchell Simoens @SenchaMitch
Sencha Inc, Senior Forum Manager
________________
http://www.JSONPLint.com - Source to lint your JSONP!
Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
https://github.com/mitchellsimoens
Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/
Need more help with your app? Hire Sencha Services services@sencha.com
Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is almost in print!
When posting code, please use BBCode's CODE tags.
-
17 Apr 2013 6:06 AM #10
Hi Mitchell,
and with my command:
why not write all-classes.js into my webapp folder? This -d option does not work?Code:sencha -cw /Users/me/Workspaces/MyPrj/src/main/webapp app build -d /Users/me/Workspaces/MyPrj/src/main/webapp
thx
Thank you for reporting this bug. We will make it our priority to review this report.


Reply With Quote