Hi Everyone, Good Morning.

Request any ones help to List All FILES from the GIT BRANCH.  
I am trying to first list Branches of a GIT REPO, then list the files of 
the BRANCH. 

I am facing problem while listing files of the BRANCH. 

I have used this code List files Of the GIT REPO with   *Extended Choice 
Parameter*. 

def gettags = ("git ls-remote -t -h 
http://pramod:[email protected]/pramod/automaticjobs.git";).execute()
return gettags.text.readLines().collect { 
  it.split()[1].replaceAll('refs/heads/', '').replaceAll('refs/tags/', 
'').replaceAll("\\^\\{\\}", '')
}

BUT this code is not working for Listing the Files of the GIT BRANCH. 

def gettags = ("git ls-remote -t -h 
http://pramod:[email protected]/pramod/automaticjobs.git -r 
{env.Branches}").execute()
return gettags.text.readLines().collect { 
  it.split()[1].replaceAll('refs/heads/', '').replaceAll('refs/tags/', 
'').replaceAll("\\^\\{\\}", '')
}



-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/fe2bb3c4-6965-44d8-aff8-d260b7f86164%40googlegroups.com.

Reply via email to