我的项目中有两个 scss 文件需要在我的 CI 构建期间进行编译(在 Azure Pipelines 上)。当我在本地构建时,一个正在编译,一个没有。我正在使用 WebCompiler,日志的输出显示了一个正在运行的文件,但没有显示丢失文件的任何错误。我的 CI 构建由 Devops 套件中的 Azure Pipelines 处理,出于某种原因,CI 构建的工作方式与本地构建不同。
最初我错过了未编译文件的 BuildAction 上的“内容”名称。我已经更正了,但它仍然没有被编译。我已经确认了 compilerconfig.json 文件的内容,并且两个文件都在那里。
这是compilerconfig.json
[
{
"outputFile": "Content/custom-bootstrap.css",
"inputFile": "Content/custom-bootstrap.scss"
},
{
"outputFile": "Content/Site.css",
"inputFile": "Content/Site.scss"
}
]
这是来自 CI 构建日志文件的片段(源自 Azure Pipelines)。
WebCompile:
WebCompiler: Begin compiling compilerconfig.json
WebCompiler installing updated versions of the compilers...
Compiled Content/custom-bootstrap.css
Minified Content/custom-bootstrap.min.css
WebCompiler: Done compiling compilerconfig.json
这是来自本地构建日志的片段。
5> WebCompiler: Begin compiling compilerconfig.json
5> Compiled Content/custom-bootstrap.css
5> Minified Content/custom-bootstrap.min.css
5> Compiled Content/Site.css
5> Minified Content/Site.min.css
5> WebCompiler: Done compiling compilerconfig.json
任何帮助将不胜感激。