peteboere / css-crush

CSS preprocessor.
http://the-echoplex.net/csscrush
MIT License
537 stars 51 forks source link

@import don't work under Windows using cli.php #42

Closed amercier closed 11 years ago

amercier commented 11 years ago

I found out that replacing

$this->docRoot = isset( $this->options->doc_root ) ?
    $this->options->doc_root : $config->docRoot;

with

$this->docRoot = str_replace('/', DIRECTORY_SEPARATOR, isset( $this->options->doc_root ) ?
    $this->options->doc_root : $config->docRoot);

in Process.php fixes the issue. You have to un-normalize the path otherwise it is looking for filepath such as C:/MyFolder/MySubFolder/etc/... instead of C:\MyFolder\MySubFolder\etc...

peteboere commented 11 years ago

Thanks for reporting this.

I've pushed a fix to the test branch. Also fixed another bug in the process so will likely be pushing a patch release soon.