Font paths aren't remapped when building with lessc -ru
Created by: ali1234
To reproduce:
git clone git://github.com/twbs/bootstrap
echo '@import "bootstrap/less/bootstrap.less";' > my.less
lessc -ru my.less | grep fonts
Expected output:
src: url('bootstrap/fonts/glyphicons-halflings-regular.eot');
src: url('bootstrap/fonts/glyphicons-halflings-regular.eot?#iefix') format('embedded-opentype'), url('bootstrap/fonts/glyphicons-halflings-regular.woff') format('woff'), url('bootstrap/fonts/glyphicons-halflings-regular.ttf') format('truetype'), url('bootstrap/fonts/glyphicons-halflings-regular.svg#glyphicons_halflingsregular') format('svg');
Actual output:
src: url('../fonts/glyphicons-halflings-regular.eot');
src: url('../fonts/glyphicons-halflings-regular.eot?#iefix') format('embedded-opentype'), url('../fonts/glyphicons-halflings-regular.woff') format('woff'), url('../fonts/glyphicons-halflings-regular.ttf') format('truetype'), url('../fonts/glyphicons-halflings-regular.svg#glyphicons_halflingsregular') format('svg');
This happens because the src urls are escaped in glyphicons.less:
src: ~"url('@{icon-font-path}@{icon-font-name}.eot')";
Removing the ~"" escaping causes the correct relative URLs to be generated:
src: url('@{icon-font-path}@{icon-font-name}.eot');
This might be the cause of https://github.com/twbs/bootstrap/issues/13336