3

I've a large project using Bootstrap3 CSS Framework. We use Netbeans IDE which supports less compile on save. Netbeans is using the syntax

Using lessc Version 2.4.0 on a Ubuntu machine installed via npm.

$ lessc less/compiled.less css/compiled.css

Full output:

"/usr/local/bin/lessc" "--source-map" "--source-map- rootpath=../themes/bodensee/less" "--source-map-url=compiled.css.map" "/usr/local/vufind2/themes/bodensee/less/compiled.less" "/usr/local/vufind2/css/compiled.css"
extend ' .clearfix' has no matches
extend ' .clearfix' has no matches
extend ' .clearfix' has no matches
extend ' .btn-xs' has no matches
 extend ' .btn-sm' has no matches
extend ' .btn-lg' has no matches
extend ' .clearfix' has no matches
extend ' .clearfix' has no matches
extend ' .clearfix' has no matches
extend ' .clearfix' has no matches
extend ' .clearfix' has no matches
extend ' .clearfix' has no matches
extend ' .img-responsive' has no matches
extend ' .clearfix' has no matches
extend ' .clearfix' has no matches
extend ' .img-responsive' has no matches
extend ' .clearfix' has no matches
Done.

I dont't know what kind of errors they are., but I find them annoying. When I try using another syntax

$ lessc less/compiled.less > css/compiled.css

it suddenly works without these messages. Netbeans offers no way to change the syntax. Anybody knows a solution?

Powerriegel
  • 595
  • 5
  • 16
  • https://github.com/timdouglas/sublime-less2css/pull/106 and http://stackoverflow.com/questions/28450144/bootstrap-bootswatch-theme-with-less-how-to-compile – websky Feb 12 '15 at 11:03
  • I already tried this. This thread is more about the compress error in the last line. I do not get this error. Updating less-plugin-clean-css does not help. – Powerriegel Feb 12 '15 at 11:07
  • In you second link, it seems that the > sign is correct and Netbeans implemented it wrong? – Powerriegel Feb 13 '15 at 08:44

2 Answers2

4

Also see: https://github.com/less/less.js/issues/2449

Less seems to threw an error when the code contains @media declaration in the main scope. As far i understand this error (warning) does not influence the extending itself.

You could safely run less with the --silent option to suppress this warning.

Bass Jobsen
  • 48,736
  • 16
  • 143
  • 224
  • This is the same answer that @michelle-glauser gave, but she also informed us of where to insert the argument into django settings. – gamen Apr 10 '15 at 08:21
3

I had this problem with a Django app, and adding this to my settings file fixed the problem:

PIPELINE_LESS_ARGUMENTS = '-s'
Michelle Glauser
  • 1,097
  • 16
  • 28