How to use Sass 1.14 with NetBeans 8.2 on Linux / macOS
我以前能够安装和使用Sass与NetBeans 8,如顶部答案中所述,如何使用SASS与Netbeans 8.0.1
现在,使用当前版本的Sass(1.14.1),安装是不同的。 基本上只需下载并解压缩。 这已经完成,我已将NetBeans指向正确的位置。 但是这个当前版本的Sass无法从NetBeans正确运行:
1 2 3 4 | "/opt/dart-sass/sass""--cache-location" "/home/jasper/.cache/netbeans/8.2/sass-compiler" "path_to_my.scss""path_to_my.css" Could not find an option named"cache-location". |
Netbeans 8.2中使用Windows的Sass输出错误也包含此错误。
我尝试将缓存位置参数(类似于Windows的解决方案)添加到
1 | exec"$path/src/dart" --no-preview-dart-2"-Dversion=1.14.1""$path/src/sass.dart.snapshot""$@" |
但我无法让它工作(同样的错误不断出现)。
有没有关于如何在Linux(Ubuntu)上从NetBeans 8.2中使用Sass 1.14.1的任何想法?
问题是
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 | #!/bin/sh # Copyright 2016 Google Inc. Use of this source code is governed by an MIT-style # license that can be found in the LICENSE file or at # https://opensource.org/licenses/MIT. # This script drives the standalone Sass package, which bundles together a Dart # executable and a snapshot of Sass. It can be created with `pub run grinder # package`. follow_links() { file="$1" while [ -h"$file" ]; do # On Mac OS, readlink -f doesn't work. file="$(readlink"$file")" done echo"$file" } # Unlike $0, $BASH_SOURCE points to the absolute path of this file. path=`dirname"$(follow_links"$0")"` shift 2 exec"$path/src/dart" --no-preview-dart-2"-Dversion=1.14.1""$path/src/sass.dart.snapshot""${@}" |
确保保留原始文件并创建仅与NetBeans一起使用的副本并在那里进行更改。
macOS(Home Brew)
如果您正在寻找Dart Sass安装位置(在使用Home Brew安装后),它位于:
1 | /usr/local/Cellar/sass/{version}/bin |
NetBeans 11
在NetBeans 11上,我不得不使用