Browse Source

Build .less file when relevant .overrides or .variables file is modified

pull/954/head
sami-t 10 years ago
parent
commit
0336c4aef4
1 changed files with 7 additions and 0 deletions
  1. 7
      src/Gruntfile.js

7
src/Gruntfile.js

@ -64,6 +64,13 @@ module.exports = function(grunt) {
if(process.platform === 'win32') {
filePath = filePath.replace(/\\/g, '/');
}
var
re = new RegExp(paths.source.themes + '.*\/([^\/]*\/[^\/]*)\.(?:overrides|variables)$')
;
// find relevant .less file for each modified .overrides or .variables file
if(filePath.search(re) !== -1) {
filePath = filePath.replace(re, paths.source.definitions + '$1.less');
}
var
outputPath = filePath.replace(paths.source.definitions, paths.output.uncompressed + 'definitions/')
;

Loading…
Cancel
Save