1

I am using Shoestrap, a WordPress theme based on Roots that uses Bootstrap and less. I added the Bootswatch Yeti theme variables.less to assets/less/bootstrap as as a replacement of the existing one and also added bootswatch.less. Then I added bootswatch.less to bootstrap.less. To recompile I ran grunt. The grunt file content I have added here. I ran into two issues though. One error I do not know how to fix and one major issue that is that grunt seems to keep on removing assets/css/main.min.css all the time and then tells me the file or directory is missing. Here are the errors I had with --force activated:

grunt --force
Running "clean:dist" (clean) task

Running "less:dist" (less) task
>> NameError: variable @gutter is undefined in assets/less/app.less on line 5, column 13:
>> 4 .gallery-row {
>> 5   padding: (@gutter / 2) 0;
>> 6 }
Warning: Error compiling assets/less/app.less Used --force, continuing.

Running "uglify:dist" (uglify) task
File "assets/js/scripts.min.js" created.

Running "version" task
Warning: ENOENT, no such file or directory 'assets/css/main.min.css' Used --force, continuing.

Done, but with warnings.

It was the Byte Order Mark (BOM) signature that was an issue as I linked to before in the question. But both TextWrangler and Dreamweaver did not remove it. I found one command that did help here: Using awk to remove the Byte-order mark And I ran

awk '{if(NR==1)sub(/^\xef\xbb\xbf/,"");print}' app.less > app.less

which worked like a charm! Only the theme still has not changed in styling. That is rather odd.

Update I

The awk command emptied my app.less. I ran another command found here as well: Using awk to remove the Byte-order mark and that command:

sed -i .bak '1 s/^\xef\xbb\xbf//' *.less

did work without removing all data from app.less, but then I got the same error again:

Reading assets/less/app.less...OK
>> NameError: variable @gutter is undefined in assets/less/app.less on line 5, column 13:
>> 4 .gallery-row {
>> 5   padding: (@gutter / 2) 0;
>> 6 }

Did see TextMate added attributes and removed those using xattr -d com.macromates.caret file.less, but that did not do the trick either.

Update II

Seems that the variable @gutter does not exist. There seems to be a variable @grid-gutter-width. Thanks to at Roots Discourse I was notified - http://discourse.roots.io/t/grunt-hits-a-snag-compiling-gutter-not-defined/940/3 . Making an adjustment does not help though as other variables pop-up as issues. Will see if I can get some feedback from the Shoestrap team.

Community
  • 1
  • 1
rhand
  • 1,176
  • 4
  • 17
  • 45

1 Answers1

1

There was a bug in the shoestrap, theme, I believe we managed to fix it with this commit: https://github.com/shoestrap/shoestrap/commit/ff75cf73cf778e4b80c5e11544c0a67717fbcc10

Please let me know if that works for you...

Aristeides
  • 168
  • 1
  • 7