Loading repository data…
Loading repository data…
eyedouble / repository
Compile Sass/Scss implemented as Erlang NIF using libsass.
A transparent discovery signal based on current public GitHub metadata.
This score does not audit code, security, maintainers, documentation quality, or suitability. Verify the repository and its current documentation before adoption.
Compile Sass/Scss implemented as Erlang NIF using libsass 3.5.1.
Please note that that Windows is only supported with Erlang/OTP 21.0 and higher. Since this release the folder containing the nif's dll is automatically added to the dll search path (OTP-14666). Erlsass uses this functionality to load it's depencency. Should you require Erlsass on Windows with a Erlang version lower than 21 feel free to use release 1.1.0.
Please note on fedora and possibly other linux distro's that use yum as package manger the g++ compiler is called gcc-c++
Simply add erlsass to the rebar.config file of your application and add to your application.src file.
Default compilation style is compressed see compile/4 for options.
erlsass:compile ( file, "foo/bar/style.scss" ).
>> {ok, "body{color:#000;}"}
Style options:
erlsass:compile ( file, "foo/bar/style.scss", "compressed" ).
>> {ok, "body{color:#000;}"}
erlsass:compile_write ( file, "foo/bar/style.scss", "foo/bar/style.css", "compressed" ).
>> ok
erlsass:compile_write ( file, "foo/bar/style.scss", "foo/bar/style.css").
>> ok
erlsass:version().
>> {ok, "Erlsass:x.x.x;Libsass:x.x.x"}
To build erlsass on Windows 64bit you need to provide GNU gcc and g++ compilers. Follow the steps below:
Download MinGW64 for Windows 64bit , and unzip to C:\mingw64.
Add C:\mingw64\bin to your Path environment variable. ( On Windows 10: Open the Start menu, type environment in the results click on Edit environment variables for your account. Select the Path entry and click on Edit. )
Open CMD or Powershell and execute gcc --version. It should show you the gcc version that is present. Do the same for g++. You are now done, please see the section Install to continue.
Note that the latest version of Erlsass on Windows is only compatible with Erlang/OTP 21 or higher.