Upgrade to SASS 3.2.5 #62

Merged
merged 2 commits into from May 16, 2013

Conversation

Projects
None yet
5 participants
Collaborator

Wintermoose commented Feb 18, 2013

Hi,
I've upgraded the embedded SASS version to 3.2.5. When I get more time to spend on this, I'd like to try to run the unit tests included with sass, but I didn't manage to find the time so far. That said, I am using the build for about 3 weeks without noticing any issues with the generated code (note: I am using the scss syntax only), and version 3.2.5 (or rather all the versions since 3.2.0.alpha) brings a whole bunch of rather cool features.

Few notes on the changes needed

  • I had to include a few extra ruby include files (related to date, mostly)
  • when building the sass_in_one.rb file, I've tried to follow the original source code approach, but in addition I had to include few fixes for IronRuby incompatibilities. All my changes are commented on lines starting with #RG, so they're easy to find. The fixes are
    • changes in group_by_to_a, since ironruby doesn't seem to implement enum.group_by
    • reimplementation of enum_with_index, as it doesn't seem to behave correctly in IronRuby (in my tests, the index is returned correctly only when iterated directly, when combined with other methods such as FIND, it fails. This particular problem affects the original SassAndCoffee as well - issues with proper merging of the css pseudoclasses
    • the negative group indexing in the scanner seems broken in IronRuby (wrong sign in the source code, actually), so I've replaced parts of tok() to use alternative

I am not exactly a Ruby guru, and the fixes above can be probably done more elegantly: so any real ruby guru is welcome to change them.

Wintermoose added some commits Jan 31, 2013

Updated to SASS version 3.2.5
Added one more core test for verification of the new SASS features
Hacked Sass::Util.enum_with_index to work correctly with IronMonkey.
This fixes the incorrect merging of pseudo classes when using the @extend command
Owner

paulcbetts commented Mar 13, 2013

Hi @Wintermoose, I'm not really maintaining this anymore. You seem interested though, so you've got commit access now, go ahead and merge this, but try to keep the style consistent.

Owner

paulcbetts commented Mar 13, 2013

Feel free to merge the other pull requests too if they look good

Collaborator

Wintermoose commented Mar 29, 2013

Hi, thanks for the offer. I am not quite sure if I am the right person for it though, because I have very little free time to look at it nowadays.

I am also not sure if I dare to merge my pull: it still compiles all I've thrown at it, but the speed becomes quite unacceptable (at least for development). I've chickened out and started using the Mindscape Workbench and while that's not quite instant either, it's probably 10x faster or so.

Without doing any profiling, I am not sure how much of that is in the original code (hard to check, as it won't compile my scss files) and how much is caused by the update: and if that's because of the sass code itself, or my hacks.

I still like the idea of SassAndCoffee, but we would need some (Iron)Ruby guru to have a look at what's going on - unfortunately that's not me.

Any ideas?

@mphrase mphrase referenced this pull request in andrewdavey/cassette May 6, 2013

Open

Cassette.Sass Unable to Handle Variable Arguments #377

paulcbetts pushed a commit that referenced this pull request May 16, 2013

@paulcbetts paulcbetts merged commit bb8c70a into paulcbetts:master May 16, 2013

jgeurts commented Jul 23, 2013

Any chance of this getting incorporated into the latest nuget?

Owner

paulcbetts commented Jul 23, 2013

@jgeurts I'll do this next week, right now I'm in Toronto and my Internet sucks

jgeurts commented Jul 24, 2013

@xpaulbettsx Awesome, thank you!

As a side note, I did run into an issue with the 3.2.5 code where relative paths for imports did not work. I would love to provide a patch, but I'm honestly at a loss for where to track that down. The SassCompiler looks like it sets the working directory in some instances, but I have no real idea how to really debug the ruby code.

kobelb commented May 12, 2014

@paulcbetts It looks like you merged this in, but I'm not seeing the changes in master. Am I missing something?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment