Are all Sass compilers the same? - sass

Is there a difference between different compilers, for example if I use node-sass or gulp-sass, and I've seen a few places with Postcss-nesting, postcss-variables and so on, is this the same thing? Is there a difference between them syntax-wise?

There are no differences in sass syntax among the compilers.
There might be other differences for which you should read the documentation of specific compiler you use.

gulp-sass is a Gulp plugin built with node-sass. You might want to check this answer for more information: stackoverflow

Related

How to use SassC on OSX

I have used sass before and it's great. But Slow. And ruby Sass is being dropped.
I'd like to swtich to a wrapper around libsass. I think that is the accepted upgrade path.
How do I do this? I've tried installing SassC via homebrew, but it doesn't seem to work the same way.
eg
sassc --watch scss:css --style compressed
fails with error, unrecognized option `--watch'
What do I need to do to get sass compilation working in the terminal using libsass?
There was a discussion in the issue section of this project. It is not implemented and nobody was working on it according to this thread. But several workarounds were posted (e.g. using fswatch or node-sass). One suggestion was to use gosass which looks quite young but supports your -watch option.
Maybe this is something for you. If not you will find probably a lot of wrappers for libsass out there.

PhpStorm - Disable generation of '.sass-cache' on compilation (file-watcher)

So, the compilation of (_)file.scss files to *.css files works great. Just one thing: For each file the watcher encounters, it creates a cache file. It does this right next to the file being compiled, e.g.:
_partial.scss
style.scss
Generates:
/.sass-cache/C0mpl1cat3dh4sh/_partial.scss
/.sass-cache/C0mpl1cat3dh4sh/style.scss
style.css
Of course I could simple delete the files when they're generated. Could add them to .gitignore. But these are work-arounds.
How to disable the generation of these cache files?
In the options I could not find an option to do this when searching "cache", "file watcher" or "watch".
Extra info:
Running 2018.3.3, built 9th January 2019
Have not seen this before, though haven't mucked around with scss in a while (2 - 3 months), so not sure if it's a recent addition to PhpStorm
Launch a terminal and find out the command-line switches offered by your SASS implementation, typically with:
sass --help
You appear to be using old Ruby SASS. If I recall correctly, the switch was:
--no-cache
Add it to the Arguments input box and you should be done.
As already mentioned, Ruby SASS is no longer being developed so it can be a good moment to switch to Dart SASS, which does not have any cache to care about.
Ruby sass is deprecated already for a while, development is moved towards Dart implementation while LibSass is also actual implementation, but may step behind Dart implementation in some aspects. LibSass have plenty of integrations for various languages, please refer documentation by link above.
Both of these implementations are much faster then Ruby sass and doesn't produce any additional cache directories.

Do i need to install xcode to install homebrew to install RUBY to install COMPASS to use SUSY?

Why do I need to install so much just to use Susy or about any sass framework?
I got really interested in using sass and sass frameworks but I can't figure out a right way to start using it. I don't get why I need to have so much installed to use just one thing. Also, I have never installed something through some sort of terminal so this freaks my out immensely, why can't I just download a zip file.
If know a useful tutorial on where to start, that would also help.
thanks in advance
Your Mac already comes with a version of Ruby (with Sierra even a recent enough version). Unless you are actively develping on different versions of Ruby, you don't need to install a custom Ruby (or even a ruby version manager).
You probably still need a compiler. Here, the xcode command line tools are sufficient. You can install them with xcode-select --install.
Generally, all these tools are comand-line oriented. It will help you tremendously if you try to get at least a high-level understanding of how the command line works and how you can use it with your tools. This will also help you when it comes to deploy your solution to a live-server, often running Linux with just the command line.
Compass is not required for Susy. In fact, Compass is no longer maintained, so I highly recommend against using it. Susy only requires Sass, but you can use any flavor of Sass - Libsass, Ruby Sass, Node Sass, Gulp Sass, etc. If it compiles Sass, it will work with Susy. There are instructions for various setups in the Susy docs.
Susy also doesn't require command-line knowledge itself, though Sass is often compiled that way. There are tools that provide GUI wrappers for Sass, if you aren't comfortable in the command line. I think CodeKit ships with Susy included.

Any good code compilers?

I am attempting to learn jade & sass however I need a good code compiler for free. Any suggestions for a good free code compiler maybe similar to codekit. Thanks!
You can use Gulp or Grunt (the most famous ones), there are plenty.
Also, Google is your friend.
If you're just getting started. I recommend just using the CLI tools that come with pug (formerly known as jade) and sass.
e.g. for pug you would do:
npm install -g pug-cli
then
pug my-pug-file.pug
For beginners who would rather work with a designed UI rather than terminal, I highly recommend Prepros.

Run Compass/SASS with a different version

I am trying to find a nice solution working on two different compass projects. One is based off Compass using Blueprint (older version), and the other is based on susy grid (newer version).
Currently, I have to reinstall the right version for the watch process.
Is it possible to run compile with a specified version? It would be great if it is also possible to run a watch process with a specified version.
Running it as
compass _0.10.5_ compile
will do what you want. (Where you put in the desired version in place of 0.10.5, obviously.)
The tool you're looking for is probally rvm which allows you to have different versions of ruby/gems installed and easily switch between them.
Perhaps there's a simpler way.
If you can use something like Codekit or Livereload, those tools allow you to used embedded sass libraries or define your own.
That you could use the builtin libraries for one project and your custom ones for other projects.
RVM suggested above also works i believe but never tried myself.

Resources