下面的常规脚本解决了该问题。该脚本可与任何支持groovy的参数插件一起使用。
def user = hudson.model.User.current();def a = jenkins.model.Jenkins.getAuthentication()def userId = user.getId() def pass =a.getCredentials()def svnurl = 'http://yoursvnurl'def dirs = [] def command = ['svn', 'list', svnurl , '--username' , userId , '--password' , pass ]def proc = command.execute()print commandproc.in.eachLine {dirs.add(it) }return dirs
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)