I’ve noticed that in _bootstrap.less, the files being imported do not have .less extensions. Because of this, whenever I go to compile Bootstrap, any file without the extension does not get compiled into “main.css.” In order for it to be compiled, I have to go in and manually add the extension.
I am using Grunt (at least I think I am). But I have a hunch all is not working properly.
When I go to setup the compiler using npm install -g grunt-cli, this is what I get. Which is terribly confusing, seeing as how I’ve setup Grunt on other machines before.
When I run npm install in the “roots” directory, all seems to work and it pulls down the necessary dependencies.
I know I’m doing something wrong, I just can’t figure out what in the world I’ve done. Thanks in advance for your help, bud.
Well, I am using Grunt. I CD into my roots directory, then run grunt watch, but nothing compiles. I’m editing the Bootstrap variables file…but I understand there is a _variables.less file, as well. Should I be editing the latter as opposed to the former? Thanks again.
@escobedorichard, grunt watch does exactly what it sounds like. It watches for changes so unless you save an edited file it won’t compile.
Run just grunt or grunt dev, grunt build, etc… Depending on what version of Roots you’re running the task may be different. They’re listed at the bottom of the gruntfile.js
The watch task in Grunt does not (by default) watch Bootstrap vendor files because they are not intended to be included in your project repo (again, by default) hence they should not be modified in an out-of-the-box Roots installation. Roots uses Bower to install Bootstrap and if you modify its LESS and then update with Bower your modifications will be lost. See more here.