Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create a SASS compiler into a standalone executable #44

Open
emagnier opened this issue Feb 18, 2012 · 4 comments
Open

Create a SASS compiler into a standalone executable #44

emagnier opened this issue Feb 18, 2012 · 4 comments

Comments

@emagnier
Copy link

Will it be possible and feasible to package the Sass compiler into a standalone executable (and without installing Ruby)?

It already exist for the .Less files (with the dotLess project) and CoffeeScript, but not for Sass, which is I think a big lack for this metalanguage.

I thinks a command line compiler should give us a lots of new ways to compile Scss files and to make solutions self-contained. For example to kick off the executable compiler as a build task, or with a PowerShell script (would be very useful in the case of a SharePoint project).

We could use it as this way:
$(SolutionDir)Tools\sass.compiler.exe $(ProjectDir)\css\styles.scss $(ProjectDir)\css\styles.css -minified

Thanks!
Etienne.

@anaisbetts
Copy link
Owner

You don't have to install a system-wide copy of Ruby, everything you need is built-in. You do need the IronRuby DLLs, but NuGet pulls them down automatically.

Paul Betts

SENT FROM MY COMMODORE 64: RESPONSES MAY BE IN ALL CAPS

On Feb 17, 2012, at 18:24, [email protected] wrote:

Will it be possible and feasible to package the Sass compiler into a standalone executable (and without installing Ruby)?

It already exist for the .Less files (with the dotLess project) and CoffeeScript, but not for Sass, which is I think a big lack for this metalanguage.

I thinks a command line compiler should give us a lots of new ways to compile Scss files and to make solutions self-contained. For example to kick off the executable compiler as a build task, or with a PowerShell script (would be very useful in the case of a SharePoint project).

We could use it as this way:
$(SolutionDir)Tools\sass.compiler.exe $(ProjectDir)\css\styles.scss $(ProjectDir)\css\styles.css -minified

Thanks!
Etienne.


Reply to this email directly or view it on GitHub:
#44

@emagnier
Copy link
Author

You are right, I don't need to install Ruby to use SassAndCoffee.
In fact I was just wondering if it was feasible to create a self-contained executable compiler, that we could use for example with a command line interpreter (like PowerShell) or a third party tool.

Thanks,
Etienne.

@kogir
Copy link
Contributor

kogir commented Feb 20, 2012

While that's definitely possible (just import SassAndCoffee.Ruby into a PowerShell CmdLet or Console project), why not use real Ruby and the official Sass gem? Performance will be better, it will follow the normal update schedule, and any bugs I've introduced won't get in your way :)

Per your example, just use:
"%Ruby%\bin\sass.bat" -t compressed "$(ProjectDir)\css\styles.scss" "$(ProjectDir)\css\styles.css"
or even better:
"%Ruby%\bin\sass.bat" -t compressed --update "$(ProjectDir)\css":"$(ProjectDir)\css"

The whole reason I got involved in SassAndCoffee is because I wanted to support real-time updates to Sass files during development. If you are willing and able to pre-compile, please think seriously about just using the established tooling.

@zaus
Copy link

zaus commented Jul 20, 2012

Aha - I think I figured it out: https://github.com/zaus/Sassifier.
(I needed it for a Sublime Text 2 plugin, and figured if it was good enough for OrangeBits, it would be good enough for me)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants