BlessCSS / bless

CSS Post-Processor
blesscss.com
MIT License
282 stars 60 forks source link

Cleanup fails when cache buster is enabled #88

Open cyberixae opened 8 years ago

cyberixae commented 8 years ago

BlessCSS version:

$ blessc -v
blessc 3.0.3 (CSS Post-Processor) [JavaScript]

Cleanup works (no cache buster):

$ blessc --no-cache-buster big.css target.css
blessc: Source CSS file contained 10,503 selectors. 3 CSS files created.
$ ls target*
target-blessed1.css target-blessed2.css target.css
$ blessc --no-cache-buster small.css target.css
blessc: Source CSS file contained 4,464 selectors. 2 CSS files created. Additional CSS file no longer needed. 1 additional file removed.
$ ls target*
target-blessed1.css target.css

Cleanup fails:

$ blessc big.css target.css
blessc: Source CSS file contained 10,503 selectors. 3 CSS files created.
$ ls target*
target-blessed1.css target-blessed2.css target.css
$ blessc small.css target.css
blessc: Source CSS file contained 4,464 selectors. 2 CSS files created.
$ ls target*
target-blessed1.css target-blessed2.css target.css
$ grep @import target.css
@import url('target-blessed1.css?z=1451559387818');
paulyoung commented 8 years ago

Hi @cyberixae, thanks for reporting this.

Cache buster was removed in v4 for a couple of reasons. I think this is tracked by #57.

The recommendation moving forward is to use a dedicated tool for cache-busting, in conjunction with bless. Is that an option for you?

I'm not doing this personally so can't recommend any particular tool or setup, but #32 might be of some help there.

cyberixae commented 8 years ago

I don't need the cache buster. I just noticed this bug while I was debugging another problem. See https://github.com/BlessCSS/gulp-bless/issues/20 for details.