[JIRA] (JENKINS-41089) Pipeline model round trip adds parenthesis where it need not add parenthesis

1 view
Skip to first unread message

jdumay@cloudbees.com (JIRA)

unread,
Jan 15, 2017, 5:51:01 PM1/15/17
to jenkinsc...@googlegroups.com
James Dumay created an issue
 
Jenkins / Story JENKINS-41089
Pipeline model round trip adds parenthesis where it need not add parenthesis
Issue Type: Story Story
Assignee: Andrew Bayer
Components: pipeline-model-definition-plugin
Created: 2017/Jan/15 10:50 PM
Priority: Minor Minor
Reporter: James Dumay

A step in the original source looks like:

sh 'mvn source:jar package -Dmaven.test.skip'

When round tripped in the editor it will come out as

sh('mvn source:jar package -Dmaven.test.skip')

While the parentheses syntax is needed for multiple arguments it would be nice to prefer the shorthand for when multiple arguments are not used.

Add Comment Add Comment
 
This message was sent by Atlassian JIRA (v7.1.7#71011-sha1:2526d7c)
Atlassian logo

andrew.bayer@gmail.com (JIRA)

unread,
Jan 17, 2017, 1:13:02 PM1/17/17
to jenkinsc...@googlegroups.com
Andrew Bayer started work on Story JENKINS-41089
 
Change By: Andrew Bayer
Status: Open In Progress

andrew.bayer@gmail.com (JIRA)

unread,
Jan 17, 2017, 3:42:02 PM1/17/17
to jenkinsc...@googlegroups.com

andrew.bayer@gmail.com (JIRA)

unread,
Jan 17, 2017, 3:43:01 PM1/17/17
to jenkinsc...@googlegroups.com

andrew.bayer@gmail.com (JIRA)

unread,
Jan 19, 2017, 5:51:06 PM1/19/17
to jenkinsc...@googlegroups.com

scm_issue_link@java.net (JIRA)

unread,
Jan 19, 2017, 5:51:06 PM1/19/17
to jenkinsc...@googlegroups.com
SCM/JIRA link daemon commented on Story JENKINS-41089
 
Re: Pipeline model round trip adds parenthesis where it need not add parenthesis

Code changed in jenkins
User: Andrew Bayer
Path:
pipeline-model-api/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/ast/ModelASTAgent.java
pipeline-model-api/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/ast/ModelASTPipelineDef.java
pipeline-model-api/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/ast/ModelASTStages.java
pipeline-model-api/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/ast/ModelASTStep.java
pipeline-model-definition/src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/endpoints/ModelConverterActionStepsTest.java
http://jenkins-ci.org/commit/pipeline-model-definition-plugin/b4d556f9075974bcb93c615cf7f59920e12915ef
Log:
Merge pull request #95 from abayer/jenkins-41090

[FIXED JENKINS-41090, JENKINS-41089] Groovy serialization cleanup

Compare: https://github.com/jenkinsci/pipeline-model-definition-plugin/compare/d17c0c7787f2...b4d556f90759

scm_issue_link@java.net (JIRA)

unread,
Jan 19, 2017, 5:51:06 PM1/19/17
to jenkinsc...@googlegroups.com

Code changed in jenkins
User: Andrew Bayer
Path:
pipeline-model-api/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/ast/ModelASTAgent.java
pipeline-model-api/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/ast/ModelASTPipelineDef.java
pipeline-model-api/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/ast/ModelASTStages.java
pipeline-model-api/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/ast/ModelASTStep.java


[FIXED JENKINS-41090, JENKINS-41089] Groovy serialization cleanup

Get rid of superfluous newlines, make sure we have a newline after
'label "foo"', don't serialize unneeded parentheses for single unnamed
arguments for steps/functions.

jdumay@cloudbees.com (JIRA)

unread,
Jan 19, 2017, 6:27:02 PM1/19/17
to jenkinsc...@googlegroups.com

bitwiseman@gmail.com (JIRA)

unread,
Oct 22, 2019, 11:25:43 PM10/22/19
to jenkinsc...@googlegroups.com
Liam Newman closed an issue as Fixed
 

Bulk closing resolved issues.

Change By: Liam Newman
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