简体   繁体   English

无法在 atom mac 上保存 sass (.scss) 文件

[英]Unable to save sass (.scss) files on atom mac

I have been trying to use sass files but whenever I try to save the file I get the error我一直在尝试使用 sass 文件,但是每当我尝试保存文件时,都会出现错误

Command failed: sass "/Users/bechara/Desktop/<path of the file>/test.scss" "/Users/bechara/Desktop/<path of the file>/test.css"
Errno::EROFS: Read-only file system @ dir_s_mkdir - ./.sass-cache
  Use --trace for backtrace.

I have the latest build of node.js installed and tried installing node-sass with npm.我安装了最新版本的 node.js 并尝试使用 npm 安装 node-sass。
The packages I tried on atom are "build-sass", "atom-sass", "sass", and "sass-autocompile".我在 atom 上尝试的包是“build-sass”、“atom-sass”、“sass”和“sass-autocompile”。

I am on macOS Catalina 10.15.4我在 macOS Catalina 10.15.4

How can I fix the issue?我该如何解决这个问题?

Can be addressed by modifying your sass_options in your config.rb file to specify a writable cache location.可以通过修改config.rb文件中的sass_options来指定可写缓存位置来解决。

sass_options = { :cache_location => '/tmp/sass_cache' }

See this answer to Codekit file permission issues (Read-only file system @ dir_s_mkdir - /.sass-cache) .请参阅Codekit 文件权限问题的答案(只读文件系统 @ dir_s_mkdir - /.sass-cache)

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

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