首页 > 解决方案 > 如何创建一个 groovy 文件来搜索 PR 中的特定文件

问题描述

我想创建一个 groovy 程序,它检查 Pull Requests(In CI) 中的特定文件并在找到时执行命令.. 这样的逻辑.. 但无法运行它。

filecheck()
{
    fileExists("./.github/codeql/codeql-config.yml")
}

如果找到文件需要执行这个命令

" codeql-runner init --repository githubreponame --github-url https://github.com"

任何参考链接将不胜感激。

标签: groovyjenkins-groovy

解决方案


推荐阅读