Looks like we can't reproduce the issue or there's a problem in the test case provided.
  1. #1
    Sencha User interfasys's Avatar
    Join Date
    Mar 2011
    Location
    UK & Switzerland
    Posts
    125
    Vote Rating
    1
    interfasys is on a distinguished road

      0  

    Default [3.1.0.192] "sencha app upgrade" tries to merge default files with current app files

    [3.1.0.192] "sencha app upgrade" tries to merge default files with current app files


    I wanted to upgrade my Sencha Touch SDK to 2.2b1, so I did a
    > sencha app upgrade <SDK>
    and the script tried to merge the basic app.js skeleton with my app.js which is totally different since it's a real app.
    Same with app.scss and config.rb.

    It also generated a totally new app id in app.json which would break things for people upgrading the app since it's used for localStorage.

    Did I do something wrong?
    Olivier - interfaSys
    Developing custom solutions for BlackBerry 10 using Sencha Touch.

  2. #2
    Sencha - Ext JS Dev Team dongryphon's Avatar
    Join Date
    Jul 2009
    Location
    Kansas
    Posts
    1,512
    Vote Rating
    176
    dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of

      0  

    Default


    Thanks for the report! I have opened a bug in our bug tracker.

  3. #3
    Sencha - Ext JS Dev Team dongryphon's Avatar
    Join Date
    Jul 2009
    Location
    Kansas
    Posts
    1,512
    Vote Rating
    176
    dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of dongryphon has much to be proud of

      0  

    Default


    In Cmd 3.1 we added the ability to do 3-way merge for generated/updated files like app.js though this is certainly a you-mileage-may-vary situation. The other behaviors sound more like bugs so I opened a ticket for this.

    On the app.js file, the merge is intended to allow the "sencha generate model" family of code generators to add items to the app.js file's "models" (or "views" etc) array. Do you use any of these commands in your environment? In Cmd 3.0, these commands had a difficult time properly extending app.js and so many people gave up on it I suspect. This should be much improved in Cmd 3.1 and its 3-way merge should allow both forms of update to collaboratively extend the file.
    Don Griffin
    Engineering Manager - Frameworks (Ext JS / Sencha Touch)

    Check the docs. Learn how to (properly) report a framework issue and a Sencha Cmd issue

    "Use the source, Luke!"

  4. #4
    Sencha User interfasys's Avatar
    Join Date
    Mar 2011
    Location
    UK & Switzerland
    Posts
    125
    Vote Rating
    1
    interfasys is on a distinguished road

      0  

    Default


    I've upgraded to 3.1.1.270 and the way things are merged are worse in my opinion. With a previous version of cmd, we were left with two files, the old one and the new one which was freshly generated. This made it relatively easy to merge changes coming from the newer version of the SDK.
    With the new system and it's everything-in-one file approach, things are messy. I'm not sure what's old and what's new.

    And to answer to your question, no I'm not using the generate family of commands.
    I've noticed an issue with the way the arrays are populated. Everything is added to app.js which directly contradicts what's in the documentation where we're told to let views handle their sub-components.
    Olivier - interfaSys
    Developing custom solutions for BlackBerry 10 using Sencha Touch.

  5. #5
    Sencha User
    Join Date
    Sep 2011
    Location
    Bologna, Italy
    Posts
    12
    Vote Rating
    0
    jeppo is on a distinguished road

      0  

    Default


    @dongryphon

    I have the same "problem" of auto-merge with my application. The problem is that my application is based on "profiles" so, most controllers and view are profile-specific and are put inside the relative profile file. The Cmd seems to ignore that and make 3 errors:
    1. put all the views/controller profile (phone/tablet) specific class inside the app.js;
    2. never put the "profile" array in the app.js main file, breaking the application;
    3. also, after the merge, it appends a "<debug>" tag after the comment lines, and every subsequent "sencha app build" compile commands breaks the resulting application (both testing/package/production) resulting in an empty "app.js" file
    Last edited by jeppo; 9 Apr 2013 at 8:11 AM. Reason: added the third error

Thread Participants: 2