I am currently working on getting automatic SCSS -> CSS conversion set up using PyCharm's File Watcher functionality. I am able to have the files output to another directory, but I cannot get them to do it relative to a specific directory. Currently, I have the following settings and relevant file tree:
Tree
|media/
|-c/
| |-css/
| |-folder/
| | |-file2.css
| --file.css
--src/
|-css/
|-folder/
| |-file2.scss
--file.scss
File Watcher Settings
- Scope is the
media/src/css/
directory and all subdirectories recursively - Arguments is
--no-cache --update $FileName$:$ProjectFileDir$/media/c/$FileDirRelativeToProjectRoot$/$FileNameWithoutExtension$.css
- Working directory is
$ProjectFileDir$/media/src/css/
- Output paths to refresh is
$ProjectFileDir$/media/c/$FileDirRelativeToProjectRoot$/$FileNameWithoutExtension$.css
With these settings, when I update file2.scss
, there is an error stating that media/c/media/src/css/folder
does not exist, which is not where I want the file anyway.
The issue that I am having is that I would like to have all paths relative to the working directory root preserved (ie. media/src/css/folder
-> media/c/css/folder
, but all of my source SCSS files are under multiple folder levels from the project root and the tutorial only specifies how to maintain folder structure if you are compiling directly below the root, not a folder below the root. Does anyone know a way that my folder structure could be preserved so that anything under media/src/css
would have the same relative output in media/c/css
?