1. #1
    Sencha User
    Join Date
    Jul 2011
    Location
    San Francisco, CA
    Posts
    103
    Vote Rating
    5
    alicexyl is on a distinguished road

      0  

    Default Sencha slice theme issue: doesn't output any error message when inputs are incorrect

    Sencha slice theme issue: doesn't output any error message when inputs are incorrect


    Not sure if this has been mentioned elsewhere, but the tool doesn't give an error msgs if something is wrong with the command, e.g. directories/files not found. It just outputs the usage info:
    Code:
    >sencha slice theme -d .\BAD-DIR -c .\resources\css\my-ext-theme.css -o .\resources\images\extjs
    usage: sencha slice theme [OPTIONS...]
    
    
     COMMAND: Theme Slicer
    
    
     DESCRIPTION:
    
    
       The Sencha Theme Slicer allows you to take your custom theme and slice up
       images for browsers that do not support border radii or linear gradients.
       This is the case for IE 6-8.
    
    
       Example:
          sencha slice theme -d ~/ext-4.0 -c mytheme.css -o mytheme -v
    
    
     OPTIONS:
    
    
     --css[=]value, -c[=]value
       The path to your theme's complete CSS file, e.g., ext-all-access.css. Uses
       the default Ext JS 4 theme CSS if not provided.
    
    
     --ext-dir[=]value, -d[=]value (required)
       The path to the root of your Ext JS 4 SDK directory.
    
    
     --manifest[=]value, -m[=]value
       The path to your Theme Generator JSON manifest file, e.g., manifest.json.
       Uses the default packaged manifest if not provided.
    
    
     --output-dir[=]value, -o[=]value
       The destination path to save all generated theme images. Defaults to the
       current working directory.
    
    
     --verbose, -v
       Display a message for every image that is generated,
    Would be great if the tool can tell us that we need to correct our input variables.

  2. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    36,610
    Vote Rating
    818
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      0  

    Default


    I have entered this in our bug tracker to look into.
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    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 in print!

    When posting code, please use BBCode's CODE tags.

  3. #3
    Sencha Premium Member
    Join Date
    Dec 2011
    Location
    London, UK
    Posts
    257
    Vote Rating
    8
    bseddon will become famous soon enough

      0  

    Default In the meantime...

    In the meantime...


    Add this line after line 78 of command/src/cliOptions.js (after 'opt = opts[key];')

    Code:
    writeln("validating..." + opt.name + " " + (isValid() ? "" : "not") + " valid");
    This line writes out the name of the argument being validated and whether the argument's validator succeeds or fails. Using the information reported you will see which arg is invalid.

    The 'sencha' script is just an argument validator which eventually runs another of the SDK programs. You can see the real command being executed by adding this line at 115 (just before the call to Cmd.execute()) of command/src/module.js:

    Code:
    writeln("Executing..." + cmd.join(''));
    To me, the underlying commands are more useful.

    Bill

Thread Participants: 2

Tags for this Thread