[JIRA] [multi-branch-project-plugin] (JENKINS-32241) Job does not resolve {GIT_BRANCH} token on first job run. Need a branch env name for build

5 views
Skip to first unread message

mjdetullio@gmail.com (JIRA)

unread,
Dec 30, 2015, 6:39:03 PM12/30/15
to jenkinsc...@googlegroups.com
Matthew DeTullio created an issue
 
Jenkins / New Feature JENKINS-32241
Job does not resolve {GIT_BRANCH} token on first job run. Need a branch env name for build
Issue Type: New Feature New Feature
Assignee: Matthew DeTullio
Components: multi-branch-project-plugin
Created: 30/Dec/15 11:38 PM
Priority: Minor Minor
Reporter: Matthew DeTullio

When branch job just created it does not resolve token `$

{GIT_BRANCH}` and (i.e. `origin/release/release_name`) and leaves it as `${GIT_BRANCH}

` plaintext.

I'm using tokens within template to separate job workspaces via custom workspace option (i.e. `\var\www\$

{GIT_BRANCH}`) to deploy branches on stagin env.

As it leaves token plaintexted it performs first build in `/var/www/${GIT_BRANCH}

` directory. But after git clone is finished it the `$

{GIT_BRANCH}` token is being expanded correctly and phing starts to use it to lookup build plan. And it expands to `/var/www/origin/release/release_name` which is correct but mismatched with the actual clone path.

I really understand that problem is that workspace is resolved before cloning and it is not really the bug or problem of plugin. But I need the way to get fully qualified branch name (`origin/release/release_name`) as a token instead of ${GIT_BRANCH}

.

Add Comment Add Comment
 
This message was sent by Atlassian JIRA (v6.4.2#64017-sha1:e244265)
Atlassian logo

mjdetullio@gmail.com (JIRA)

unread,
Dec 30, 2015, 7:12:02 PM12/30/15
to jenkinsc...@googlegroups.com
Matthew DeTullio updated an issue
Change By: Matthew DeTullio
Original reporter [~scaytrase]

When branch job just created it does not resolve token `${GIT_BRANCH}` and (i.e. `origin/release/release_name`) and leaves it as `${GIT_BRANCH}` plaintext.

I'm using tokens within template to separate job workspaces via custom workspace option (i.e. `\var\www\${GIT_BRANCH}`) to deploy branches on stagin env.

As it leaves token plaintexted it performs first build in `/var/www/${GIT_BRANCH}` directory. But after git clone is finished it the `${GIT_BRANCH}` token is being expanded correctly and phing starts to use it to lookup build plan. And it expands to `/var/www/origin/release/release_name` which is correct but mismatched with the actual clone path.

I really understand that problem is that workspace is resolved before cloning and it is not really the bug or problem of plugin. But I need the way to get fully qualified branch name (`origin/release/release_name`) as a token instead of ${GIT_BRANCH}.

mjdetullio@gmail.com (JIRA)

unread,
Dec 30, 2015, 7:31:01 PM12/30/15
to jenkinsc...@googlegroups.com

adrien.lecharpentier@gmail.com (JIRA)

unread,
May 25, 2016, 11:47:03 AM5/25/16
to jenkinsc...@googlegroups.com
Adrien Lecharpentier updated an issue
Original reporter [~scaytrase]

When branch job just created it does not resolve token
 `  {{ ${GIT_BRANCH} ` }}  and (i.e. {{origin/release/release_name}}) and leaves it as `${GIT_BRANCH}` plaintext.

I'm using tokens within template to separate job workspaces via custom workspace option (i.e. `\var\www\${GIT_BRANCH}`) to deploy branches on stagin env.

As it leaves token plaintexted it performs first build in `/var/www/${GIT_BRANCH}` directory. But after git clone is finished it the `${GIT_BRANCH}` token is being expanded correctly and phing starts to use it to lookup build plan. And it expands to {{/var/www/origin/release/release_name}} which is correct but mismatched with the actual clone path.

I really understand that problem is that workspace is resolved before cloning and it is not really the bug or problem of plugin. But I need the way to get fully qualified branch name ({{origin/release/release_name}}) as a token instead of ${GIT_BRANCH}.
Add Comment Add Comment
 

adrien.lecharpentier@gmail.com (JIRA)

unread,
May 25, 2016, 11:48:01 AM5/25/16
to jenkinsc...@googlegroups.com

mjdetullio@gmail.com (JIRA)

unread,
Jul 1, 2016, 4:58:02 PM7/1/16
to jenkinsc...@googlegroups.com
Matthew DeTullio updated an issue
Change By: Matthew DeTullio
Component/s: git-plugin
This message was sent by Atlassian JIRA (v7.1.7#71011-sha1:2526d7c)
Atlassian logo

mjdetullio@gmail.com (JIRA)

unread,
Jul 1, 2016, 4:58:02 PM7/1/16
to jenkinsc...@googlegroups.com

mjdetullio@gmail.com (JIRA)

unread,
Jul 1, 2016, 4:58:02 PM7/1/16
to jenkinsc...@googlegroups.com

mjdetullio@gmail.com (JIRA)

unread,
Jul 1, 2016, 4:58:02 PM7/1/16
to jenkinsc...@googlegroups.com

mark.earl.waite@gmail.com (JIRA)

unread,
Oct 22, 2019, 9:34:19 PM10/22/19
to jenkinsc...@googlegroups.com
Mark Waite closed an issue as Duplicate
Change By: Mark Waite
Status: Resolved Closed
This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)
Atlassian logo
Reply all
Reply to author
Forward
0 new messages