You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

White Source Azure DevOps任务excludes参数无法生效问题求助

你遇到的excludes参数不生效问题,核心原因是WhiteSource Unified Agent的配置项命名规则问题,直接使用excludes属于无效参数,会被解析器忽略,因此日志中会显示带#注释的空值。

修正方案

  1. 替换配置项名称,在excludes前添加project.前缀,修正后的流水线配置如下:
- task: WhiteSource@21
  inputs:
    cwd: '$(System.DefaultWorkingDirectory)/sources/'
    configuration: |
      project.excludes=**/Examples/**
      case.sensitive.glob=false
      followSymbolicLinks=true
  1. 额外验证项:
  • 若使用Linux/macOS代理,建议确保glob路径的大小写与实际目录完全匹配,避免大小写敏感导致的匹配失效
  • 可在WhiteSource任务前增加目录打印任务,确认Examples目录的相对路径与**/Examples/**规则匹配,示例命令:
    • Linux代理:find $(System.DefaultWorkingDirectory)/sources/ -type d -name "*Examples*"
    • Windows代理:Get-ChildItem -Path $(System.DefaultWorkingDirectory)/sources/ -Recurse -Directory -Filter "*Examples*"
  • 确认使用的WhiteSource@21任务为最新版本,部分旧版本存在多行配置解析缺陷。

内容的提问来源于stack exchange,提问作者Alexander Lysenko

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.10.07 10:18:03