SCSS / SASS to CSS in special folder with PHPstorm 7 file watcher

17,859

Solution 1

AAAAAAArrrgh!

the "backslashes" were the problem.

output path

$FileParentDir$/css/$FileNameWithoutExtension$.css

enter image description here

Solution 2

To place rendered with PHPStorm File Watcher css file in css directory and keep sass file in sass directory I've changed Arguments and Output paths to refresh.

Arguments field:

--no-cache --update $FileName$:$FileParentDir$/css/$FileNameWithoutExtension$.css --style expanded 

you can remove --style expanded if you want to see css with additional spaces as it is looking in sass. this argument is only changing the indents in css file to old fashioned and drupal requires this.

and Output paths to refresh field:

$FileParentDir$/css/$FileNameWithoutExtension$.css
Share:
17,859

Related videos on Youtube

user2310852
Author by

user2310852

Updated on July 04, 2022

Comments

  • user2310852
    user2310852 almost 2 years

    I used PHPstorm 6 and my SCSS-Files were compiled into the CSS-Folder, so I have:

    css
      -- main.css
    img
    js
    scss
      -- main.scss
      -- _variables.scss   ...
    

    Hier are my definitions on SCSS File Watcher enter image description here

    Everthing worked fine, but yesterday I updated my PHPstorm from version 6 to 7 and now my SCSS compile / file watcher are not working anymore. The File Watcher compile the CSS-File into the SCSS-Folder. But I want it in my CSS-Folder!!!

    What are your settings in PHPstorm 7 Filewatcher for SCSS Files?

    here is my data structure, you'll see the file style.css with FileDirName/css/style.css one folder "to high" .. enter image description here

  • gabe3886
    gabe3886 almost 9 years
    Even Windows is picky about this, as I've just found out. Windows doesn't normally care, but seems to for the PhpStorm watchers.
  • Radmation
    Radmation over 5 years
    Thanks! This is poorly documented in the PHPStorm Docs.