Closed grisumbras closed 5 years ago
Did you try the -I
parameter https://github.com/sass/sassc/issues/209#issuecomment-298469284
The parameter does work. In some cases the environment variable is more convenient, though.
I should probably elaborate on my use case.
I am planning to use sassc in a build process. The package that is being built will declare several dependencies, including those that contain Sass files. The package managing system I am using (Conan) allows packages to provide information on how to use them to consumers. One of the good ways to do this is environment variables. For example, packages that provide pkg-config package descriptions modify consumers' PKG_CONFIG_PATH. Packages that provide CMake modules use CMAKE_PREFIX_PATH. And so on.
If a package with Sass files adds its installation directory to consumers' SASS_PATH and then sassc uses that variable, then no further configuration for sassc is required.
Ruby version of Sass documents environment variable
SASS_PATH
to used to add load paths. sassc doesn't seem to. This feature is very usefull when Sass files come from different sources and can be located in different directories and paths to those directories may vary depending on situation. In particular, if the files are pulled by a package manager.