-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
sprite-path() does not honor the generated_images_dir path. #1077
Comments
Hi @scottdavis, I'm still experiencing this issue in 0.12.2. It looks like the fix is on the allowed_extensions branch, I'm not sure how to utilise it in my version of Compass. I'm using grunt-contrib-compass with the following image settings:
If I run
I get:
|
Sorry, just realised this is now in 0.13, I changed my Gemfile like so and it's working: gem 'sass', "3.3.0.rc.1" Thanks, |
when is this planned to the stable version? |
@munichlinux I will release 1.0 in the next couple weeks. |
No fix for more than 1 year :(
|
Workaround, just put this into your config.rb:
|
I'm assuming this is fixed in the latest version, 1.0.0.alpha.19? Unfortunately I get |
Yes, but its alpha, so we need to wait for stable release |
@AndrewDryga Your workaround didn't seem to work for me. Was there anything else I needed to add to config.rb for this? |
Here is my config:
|
Updated to latest version, Compass 1.0.0.alpha.20, and now my workaround is broken. Can someone assist? I don't know Ruby |
New monkey patch that work for both versions in same time:
|
I created the following function on my project as a workaround for this bug. I know this is not a clean solution, but it solves my need at this moment without changing any compass ruby files. In my case, I'm using grunt-contrib-compass with the following settings: ...
imagesDir: 'app/images',
generatedImagesDir: '.tmp/images/generated',
... So in my function, I'm just pointing to the generatedImagesDir relatively to my imagesDir: @function sprite-path-fix($sprite-map) {
$generated-path: "../../.tmp/images/generated/";
$path: #{$generated-path}#{sprite-path($sprite-map)};
@return $path;
} I hope this could help someone experiencing a similar issue. |
In compass 1.0.1 this is still broken. :( |
@marteb developers don't bother about bugs, just closing it without comments. See #1715 |
Sprites are going through a transformation to their own gem right now soon as chris approves the PR I will get this fixed and out with 1.0.1.rc |
Can I get an update on this issue, has anyone got a fix for it? |
@jasonalvis nope, i have workaround few posts above, thats all |
I had the same problem today after update to 1.1.0.alpha.3. I did rollback to 1.0.0.rc.1 and it worked normally again. Can you check if this last one works for you? If it does I can try to look the code changes and find the bug. Thanks |
This monkey patch fixes it. Compass/compass#1077 (comment)
The workarounds above didn't work for me. What ended up working was just removing the |
I've noticed that when setting the
generated_images_dir
in theconfig.rb
that thesprite-path()
function will still use theimages_dir
as the basis for the resulting path.Example:
Inside my
config.rb
:Inside my
application.scss
:Output of the
debug()
ismy-sprites.png
when it should've beensprites/my-sprites.png
.Is this a bug or am I missing the point on what the
sprite-path
should be used for?Thanks for taking a look.
The text was updated successfully, but these errors were encountered: