1. #1
    Ext JS Premium Member
    Join Date
    Jun 2007
    Location
    Siberia
    Posts
    9
    Vote Rating
    0
    johnny is on a distinguished road

      0  

    Default How to generate sprites by compass?

    How to generate sprites by compass?


    Hello,

    How to generate sprites using compass like this in Extjs 4.2 (Sencha Cmd 3.1.0.256)?
    @import "../resources/images/*.png";
    @include all-icons-sprites;

    Images locates under "resources/images" in application and copied to build/production/resources during application build process but after that I got this error:

    Code:
    [INF] executing compass using system installed ruby runtime
    Errno::EINVAL on line ["38"] of C: Invalid argument - C:/www/influencing4/web/v42/build/Influencing/production/.sass-cache/a446d67f29cb0b97532ab6943548eaa1587f5329/*.pngc  C:/bin/Sencha/Cmd/3.1.0.256/extensions/sencha-compass/gems/gems/sass-3.1.7/lib/sass/cache_stores/filesystem.rb:38:in `open'  C:/bin/Sencha/Cmd/3.1.0.256/extensions/sencha-compass/gems/gems/sass-3.1.7/lib/sass/cache_stores/filesystem.rb:38:in `_store'
    Is anybody know how to fix this?

  2. #2
    Sencha User
    Join Date
    Jun 2011
    Posts
    3
    Vote Rating
    0
    mkolmogorov is on a distinguished road

      0  

    Default


    I faced similar thing using SenchaCmd-3.1.1.274.

    There are no errors now and images are copied tobuild/production/resources

    But there are no new sprites and styles for them.

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

      0  

    Default


    I haven't started upgrading from 4.1 to 4.2 yet, but what happens if you try this?
    Code:
    @import "*.png";
    @include all-icons-sprites;
    
    Seems like resource/images should be configured as the images_dir for Compass by Sencha Cmd.

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

      0  

    Default


    I just tried this, same result. Looks like Compass config images_dir/images_path are not set correctly. image-url() is broken too:
    Code:
    [INF] executing compass using system installed ruby runtime
    WARNING: 'icon_save.png' was not found (or cannot be read) in C:/Users/alicexyl/my-workspace/packages/ri-theme/build/images/common
    I consider this high priority, because we cannot take advantage of Compass in writing image or sprite rules in sass/etc, which makes upgrading from 4.1 enormously difficult. Please provide a workaround, and fix this soon.

  5. #5
    Touch Premium Member
    Join Date
    Sep 2011
    Posts
    47
    Vote Rating
    1
    ruslan.talpa is on a distinguished road

      0  

    Default


    Any progress on this anyone?

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

      0  

    Default


    ruslan.talpa, we're using a workaround to avoid using Sencha Cmd altogether. Please see SebTardif 's post on 21 Mar 2013 6:26 AM here:
    http://www.sencha.com/forum/showthre...ile-structures