Ruby 代码包文件权限问题(只读文件系统@dir\u s\u mkdir-/.sass缓存)
获取以下错误:Ruby 代码包文件权限问题(只读文件系统@dir\u s\u mkdir-/.sass缓存),ruby,sass,permissions,compass-sass,codekit,Ruby,Sass,Permissions,Compass Sass,Codekit,获取以下错误: Compiling failed with this error: Errno::EROFS on line ["239"] of /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/fileutils.rb: Read-only file system @ dir_s_mkdir - /.sass-cache Run with --trace to see the full back
Compiling failed with this error: Errno::EROFS on line ["239"] of /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/fileutils.rb: Read-only file system @ dir_s_mkdir - /.sass-cache
Run with --trace to see the full backtrace
真的很痛苦,任何帮助都将不胜感激
发生在我更新Mac OS Catalina之后。
当前在10.15.1(19B88)上。
/。sass缓存将是文件系统根目录下的sass缓存目录。它不应该试图在那里创建那个目录
但是,这个Ruby正在运行,它没有使用正确的工作目录运行,或者需要传递一个基本路径才能运行。在Catalina中,Ruby Sass尝试写入缓存的磁盘根现在是只读的,因此它失败了
我用波旁威士忌代替了。我自己也在compass中创建了一些mixin。Ruby Sass不受欢迎。
在代码工具包3中,您应该改用libsass编译器。
如果使用Compass,则Libsass不可用。
如果是,您可以在config.rb中设置缓存位置路径:
sass_选项={:缓存位置=>'/tmp/sass_缓存'}添加
line_comments = false
output_style = :compressed
sourcemap = true
asset_cache_buster = :none
cache = false
到我的config.rb文件修复了这个问题。我该怎么做?@AsaadMahmood我不知道。您没有在问题中包含任何信息来指示您运行什么程序来获取此错误我在通过“Codekit”编译时遇到此错误。对于版本3.12.1+,Dart Sass现在是默认的Sass编译器。您仍然需要在带有Dart sass的config.rb中添加sass_选项={:cache_location=>'/tmp/sass_cache'}
。