Having some sort of env variable is possible with Ruby Sass through custom functions.
node-sass doesn't have that (yet) though, but that doesn't keep us from doing what we want.
Here is an example. In the JavaScript script, we check for SASS_ENV
presence and change the Sass $ENV
variable accordingly.
If you use sass-mq, this is useful to toggle the helper:
$ export SASS_ENV=development && node compile
variables.scss:11: DEBUG: current env is development, meaning $mq-show-breakpoints is "mobile, mobileLandscape, tablet, desktop, wide"
$ export SASS_ENV=production && node compile
stdin:12: DEBUG: current env is production, meaning $mq-show-breakpoints is ""