如何在 "remoteJenkinsFileWorkflowMultiBranchProjectFactory" 上下文中描述 "remoteJenkinsFileSCM()" 的值?

How to describe the value for "remoteJenkinsFileSCM()" in the "remoteJenkinsFileWorkflowMultiBranchProjectFactory" context?

尝试定义 groovy dsl 脚本以生成 "Github Organization Folder" 作业配置,使用 "Remote File Plugin" 定义集中式 Jenkinsfile

organizationFolder("${org}") {
    description('This contains branch source jobs for Bitbucket and GitHub')
    displayName("${org}")
    triggers {
        cron('@daily')
    }
    organizations {
        github {
            repoOwner("${org}")
            credentialsId('myCreds')
            apiUri('myGithubUr')
        }
    }
    projectFactories {
        remoteJenkinsFileWorkflowMultiBranchProjectFactory {
            localFile('something')
            remoteJenkinsFile('Jenkinsfile')
            matchBranches(false)
            remoteJenkinsFileSCM()
        }
    }
}

不确定要在上面的代码中传递什么值 "remoteJenkinsFileSCM()",希望在配置中选择 "Git" 作为选项。一个例子将非常有帮助和赞赏。

使用 UI 手动配置作业。然后查看作业的 config.xml 并将其转换为作业 DSL。 XML 元素和 Job DSL 语法之间的映射应该非常相似。使用嵌入式作业 DSL API 查看器作为确切语法的参考。

远程文件插件页面包含手动配置作业的示例,请参阅 https://plugins.jenkins.io/remote-file。要获得 config.xml,只需将 config.xml 添加到职位页面 URL,例如http://localhost:8080/job/example/config.xml。您需要使用 Chrome 才能查看该页面。