Use import paths from themes when loading a less sheet

This commit is contained in:
Ben Ogle
2013-08-13 17:02:08 -07:00
parent b89e58e551
commit 3bc6023a66

View File

@@ -138,10 +138,12 @@ window.loadStylesheet = (stylesheetPath) ->
fsUtils.read(stylesheetPath)
window.loadLessStylesheet = (lessStylesheetPath) ->
importPaths = atom.themes.getImportPaths()
parser = new less.Parser
syncImport: true
paths: config.lessSearchPaths
paths: importPaths.concat(config.lessSearchPaths)
filename: lessStylesheetPath
try
content = null
parser.parse fsUtils.read(lessStylesheetPath), (e, tree) ->