[JIRA] (JENKINS-59341) patterns arg not being evaluated by the DSL plugin

12 views
Skip to first unread message

drew.waranis@sonos.com (JIRA)

unread,
Sep 12, 2019, 10:51:02 PM9/12/19
to jenkinsc...@googlegroups.com
Drew Waranis created an issue
 
Jenkins / Bug JENKINS-59341
patterns arg not being evaluated by the DSL plugin
Issue Type: Bug Bug
Assignee: Oliver Gondža
Components: ws-cleanup-plugin
Created: 2019-09-13 02:50
Environment: Jenkins ver. 2.73.3, Workspace Cleanup Plugin 0.34
and
Jenkins ver. 2.176.3, Workspace Cleanup Plugin 0.37
Priority: Minor Minor
Reporter: Drew Waranis

This snippet compiles correctly, but the pattern is not included in ws-cleanup's box in the job config GUI:

job.publishers {
    cleanWs {
        cleanWhenAborted(true)
        cleanWhenFailure(true)
        cleanWhenNotBuilt(true)
        cleanWhenSuccess(true)
        cleanWhenUnstable(true)
        deleteDirs(true)
        patterns: [
            [
                pattern: '.propsfile',
                type: 'EXCLUDE'
            ]
        ]
    }
}

Thank you for the help!

Add Comment Add Comment
 
This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)
Atlassian logo

drew.waranis@sonos.com (JIRA)

unread,
Sep 20, 2019, 2:34:02 PM9/20/19
to jenkinsc...@googlegroups.com
Drew Waranis commented on Bug JENKINS-59341
 
Re: patterns arg not being evaluated by the DSL plugin

Any update here? This is blocking work.

ogondza@gmail.com (JIRA)

unread,
Dec 17, 2019, 4:44:02 AM12/17/19
to jenkinsc...@googlegroups.com

Thanks for the report! Have this syntax ever worked? Where did you get that?

The DSL generated on my instance suggests something like:

patterns {
    pattern {
        pattern(String value)
        type(String value)
    }
} 

Which I have not made to work either.

ogondza@gmail.com (JIRA)

unread,
Dec 17, 2019, 4:55:03 AM12/17/19
to jenkinsc...@googlegroups.com
Oliver Gondža edited a comment on Bug JENKINS-59341
Thanks for the report! Have this syntax ever worked? Where did you get that?

The DSL generated on my instance suggests something like:

{noformat}

patterns {
    pattern {
        pattern(String value)
        type(String value)
    }
}
{noformat}

- Which I have not made to work either. -

ogondza@gmail.com (JIRA)

unread,
Dec 17, 2019, 4:56:03 AM12/17/19
to jenkinsc...@googlegroups.com

Ok, so I have tested this syntax is accepted by job DSL plugin:

publishers {
    cleanWs {
        cleanWhenAborted(true)
        cleanWhenFailure(true)
        cleanWhenNotBuilt(false)
        cleanWhenSuccess(true)
        cleanWhenUnstable(true)
        deleteDirs(true)
        notFailBuild(true)
        disableDeferredWipeout(true)
        patterns {
            pattern {
                type('EXCLUDE')
                pattern('.propsfile')
            }
            pattern {
                type('INCLUDE')
                pattern('.gitignore')
            }
        }
    }
}

ogondza@gmail.com (JIRA)

unread,
Dec 17, 2019, 7:20:03 AM12/17/19
to jenkinsc...@googlegroups.com
Oliver Gondža started work on Bug JENKINS-59341
 
Change By: Oliver Gondža
Status: Open In Progress

ogondza@gmail.com (JIRA)

unread,
Dec 18, 2019, 6:59:03 AM12/18/19
to jenkinsc...@googlegroups.com
Oliver Gondža closed an issue as Not A Defect
 

I am closing this as not a defect. Feel free to reopen in case there are some tools / docs that advise this syntax.

Change By: Oliver Gondža
Status: In Progress Closed
Resolution: Not A Defect

ogondza@gmail.com (JIRA)

unread,
Dec 18, 2019, 6:59:03 AM12/18/19
to jenkinsc...@googlegroups.com
Oliver Gondža edited a comment on Bug JENKINS-59341
Thanks for the report! Have this syntax ever worked? Where did you get that?

The DSL reference generated on my instance suggests something like:

{noformat}
patterns {
    pattern {
        pattern(String value)
        type(String value)
    }
}
{noformat}

-Which I have not made to work either.-
Reply all
Reply to author
Forward
0 new messages