I just installed Compass 0.11.5 on Windows 7 with Ruby 1.9.2.
I have my development environment set up to use Unix line endings for all files.
I created an initial sass-test project and noticed that all the files it created had Windows line endings. I moved an existing .css file from another project (with unix line endings) into the sass folder and changed the extension to .scss. I ran the 'compass compile' command to generate the .css file for this new file and the .css file it created had Windows line endings.
I can't find any configuration options in the Compass documentation to force Compass to generate files with Unix line endings.
Is it possible to configure Compass to generate files with Unix line endings on Windows?
After further investigation, there is an option to to pass configuration options to Sass from Compass.
Property Name Type Description
sass_options Hash These options are passed directly to the Sass compiler. For more details on the format of sass options, please read the sass options documentation.
Sass has an option for generating unix line endings:
:unix_newlines
If true, use Unix-style newlines when writing files. Only has meaning on Windows, and only when Sass is writing the files (in Rack, Rails, or Merb, when using Sass::Plugin directly, or when using the command-line executable).
It appears that adding the following line to the sass-test project's config.rb file should solve the issue:
sass_options = {:unix_newlines => true}
But, it doesn't have any effect on the resulting .css files created - they still have Windows line endings.
According to https://github.com/chriseppstein/compass/issues/949 it should be fixed in sass 3.1.20 but on my box no joy... still Windows line endings
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With