简体   繁体   English

指南针手表和.sass缓存

[英]Compass watch and .sass-cache

(I added the line wp-content/themes/klasik-child/mysass/.sass-cache in the file .gitignore from) when I execute "Compass watch" I have this error: 当我执行“指南针监视”时,在文件.gitignore中添加了wp-content / themes / klasik-child / mysass / .sass-cache行) ,我遇到此错误:

Errno::ENOENT on line ["247"] of C: No such file or directory'
 -C:\Program Files (x86)\EasyPHP-DevServer-14.1VC9\data\localweb\github2015\myproject\wp-content\themes\klasik-child\mysass\.sass-cache\75fcaf1b4852ceb732871195e41567cc2a7d8997
C%058C:\Program Files (x86)\EasyPHP-DevServer-14.1VC9\data\localweb\github2015
run with --trace to see the full backtrace

Yet 75fcaf1b4852ceb732871195e41567cc2a7d8997 and github2015 folder exists. 但是存在75fcaf1b4852ceb732871195e41567cc2a7d8997和github2015文件夹。

I reset my .gitingnore file and I tried to delete the folder ".sass-cache" but I still have the same problem. 我重置了.gitingnore文件,并尝试删除文件夹“ .sass-cache”,但仍然存在相同的问题。

I tried adding sass_options = {:cache_location => "path\\to\\tmp\\sass-cache"} in config.rb but it gives errors "mkdir" invalid argument - path 我尝试在config.rb中添加sass_options = {:cache_location => "path\\to\\tmp\\sass-cache"} ,但给出错误"mkdir" invalid argument - path

thank ! 谢谢 !

++ Other info : ++其他资讯:

1- Command is run here : C:\\Program Files (x86)\\EasyPHP-DevServer-14.1VC9\\data\\localweb\\github2015\\myproject\\wp-content\\themes\\klasik-child\\mysass from windows command 1-在这里运行命令:C:\\ Program Files(x86)\\ EasyPHP-DevServer-14.1VC9 \\ data \\ localweb \\ github2015 \\ myproject \\ wp-content \\ themes \\ klasik-child \\ mysass从Windows命令

2- directory structure 2-目录结构

mysass
|---css
     |----principal.css
|---images
|---sass
     |----partials
           |-----_accueil.scss
     |----pricipal.scss
config.rb

3- config.rb 3- config.rb

require 'compass/import-once/activate'

http_path = "/"
css_dir = "css"
sass_dir = "sass"
images_dir = "images"
javascripts_dir = "javascripts"
# sass_options = {:cache_location => "path\to\tmp\sass-cache"}
relative_assets = true
line_comments = false

I found the solution here: Compass/SASS - not all files are compiled 我在这里找到解决方案: Compass / SASS-并非所有文件都已编译

Indeed, The problem exists only if I change _accueil.scss (PARTIALS). 确实,仅当我更改_accueil.scss(PARTIALS)时,问题才存在。 When I change pricipal.scss no compilation problem. 当我更改pricipal.scss时,没有编译问题。 When I change _accueil.scss of type I errors 'No such file or directory ...sass-cache/..' – 当我更改类型_accueil.scss时出现错误“没有此类文件或目录... sass-cache / ..” –

If I comment the first line of config.rb # require 'compass/import-once/activate' it is no more problem of compilation : all my stylesheets they are compiled normally. 如果我注释config.rb的第一行,则# require 'compass/import-once/activate'这不再是编译问题:我的所有样式表都可以正常编译。

I had the same issue it turns out my .sass-cache path was too long, and the file was silently failing and not being outputted to that directory. 我遇到了同样的问题,结果是我的.sass-cache路径太长,并且文件无提示地失败并且没有输出到该目录。 It never mentioned anywhere that my path was too long, I was trying a suggestion found here: 它从未在任何地方提到我的道路太长,我正在尝试在这里找到的建议:

https://github.com/Compass/compass/issues/1791 https://github.com/Compass/compass/issues/1791

To fix it, Add this line to to your config.rb 要解决此问题,请将此行添加到您的config.rb中

cache_path = 'C:\temp\sass'

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM