Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

CSS

Drew Butcher
Drew Butcher
33,160 Points

SCSS styling in Sublime

How can one tell sublime text 2 to recognize SCSS for the fancy color code stylings and predictive text.

In the bottom right corner of the Sublime window there is an option to change file extension but SCSS is not one of the options :( Presently I am choosing the option CSS for writing SCSS files but it's not perfect.

Many Thanks, Drew Butcher

3 Answers

Pedro GCA
Pedro GCA
20,683 Points

Hey Drew, there are the instructions:

  1. Cmd + Shift + P
  2. Package Control: Install Package
  3. Search for Sass and Install it.

If you don't have the package control installed on sublime then:

  1. Open the console in sublime (View - Show Console).
  2. Paste the code below and hit enter.
  3. Wait until the package control is installed.
  4. Execute the first process that I wrote above.

Code to install package control:

import urllib2,os,hashlib; h = '7183a2d3e96f11eeadd761d777e62404' + 'e330c659d4bb41d3bdf022e94cab3cd0'; pf = 'Package Control.sublime-package'; ipp = sublime.installed_packages_path(); os.makedirs( ipp ) if not os.path.exists(ipp) else None; urllib2.install_opener( urllib2.build_opener( urllib2.ProxyHandler()) ); by = urllib2.urlopen( 'http://sublime.wbond.net/' + pf.replace(' ', '%20')).read(); dh = hashlib.sha256(by).hexdigest(); open( os.path.join( ipp, pf), 'wb' ).write(by) if dh == h else None; print('Error validating download (got %s instead of %s), please try manual install' % (dh, h) if dh != h else 'Please restart Sublime Text to finish installation')

I hope it helps ;). Let me know.

Pedro GCA
Pedro GCA
20,683 Points

SASS and SASS Snippets are good. They will Give you everything you need Drey.

Drew Butcher
Drew Butcher
33,160 Points

That works perfectly! Thank you :)

Drew Butcher
Drew Butcher
33,160 Points

Hey Pedro,

Thank you, I just have one more questions. When I follow the above directions I see:

"SASS", "SASS Build", "SASS Snippets", "SassBeautify", and "SassBuilder".

Which of these do you recommend?

Thank you, Drew Butcher