Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

no back to line in the generated file #42

Open
sbuisson opened this issue Sep 5, 2017 · 6 comments
Open

no back to line in the generated file #42

sbuisson opened this issue Sep 5, 2017 · 6 comments

Comments

@sbuisson
Copy link

sbuisson commented Sep 5, 2017

the generated file appear to me as one block of code, without identation nor /n, can you correct-it?

I suspect it's an html issue.
Also, there is strange things like #(Element:0x9c28a4 {

@visualphoenix
Copy link
Owner

visualphoenix commented Sep 5, 2017 via email

@sbuisson
Copy link
Author

I use a mac, with chrome.

@sbuisson
Copy link
Author

sbuisson commented Sep 10, 2017

pipelineJob('20170905063733') {
keepDependencies(false)
properties {
#(Element:0x9c34ac {
name = "org.jenkinsci.plugins.workflow.job.properties.PipelineTriggersJobProperty",
children = [
#(Text "\n "),
#(Element:0x9c28a4 {
name = "triggers",
children = [
#(Text "\n "),
#(Element:0x9d3f00 {
name = "org.jenkinsci.plugins.ghprb.GhprbTrigger",
attributes = [
#(Attr:0x9d3c08 { name = "plugin", value = "ghprb@1.39.0" })],
children = [
#(Text "\n "),
#(Element:0x9d2b50 {
name = "spec",
children = [ #(Text "H/5 * * * ")]
}),
#(Text "\n "),
#(Element:0x60a6a8 {
name = "configVersion",
children = [ #(Text "3")]
}),
#(Text "\n "),
#(Element:0x9d7420 { name = "adminlist" }),
#(Text "\n "),
#(Element:0x9d6c50 {
name = "allowMembersOfWhitelistedOrgsAsAdmin",
children = [ #(Text "false")]
}),
#(Text "\n "),
#(Element:0x609f78 { name = "orgslist" }),
#(Text "\n "),
#(Element:0x5ff104 {
name = "cron",
children = [ #(Text "H/5 * * * ")]
}),
#(Text "\n "),
#(Element:0x5f940c { name = "buildDescTemplate" }),
#(Text "\n "),
#(Element:0x5f67fc {
name = "onlyTriggerPhrase",
children = [ #(Text "false")]
}),
#(Text "\n "),
#(Element:0x5f2968 {
name = "useGitHubHooks",
children = [ #(Text "false")]
}),
#(Text "\n "),
#(Element:0x5ef510 {
name = "permitAll",
children = [ #(Text "false")]
}),
#(Text "\n "),
#(Element:0x9d7894 { name = "whitelist" }),
#(Text "\n "),
#(Element:0x9d7088 {
name = "autoCloseFailedPullRequests",
children = [ #(Text "false")]
}),
#(Text "\n "),
#(Element:0x9d63b8 {
name = "displayBuildErrorsOnDownstreamBuilds",
children = [ #(Text "false")]
}),
#(Text "\n "),
#(Element:0x9d33c0 {
name = "whiteListTargetBranches",
children = [
#(Text "\n "),
#(Element:0x9d290c {
name = "org.jenkinsci.plugins.ghprb.GhprbBranch",
children = [
#(Text "\n "),
#(Element:0x9c3c90 { name = "branch" }),
#(Text "\n ")]
}),
#(Text "\n ")]
}),
#(Text "\n "),
#(Element:0x9c214c {
name = "blackListTargetBranches",
children = [
#(Text "\n "),
#(Element:0x9ba384 {
name = "org.jenkinsci.plugins.ghprb.GhprbBranch",
children = [
#(Text "\n "),
#(Element:0x9b03ac { name = "branch" }),
#(Text "\n ")]
}),
#(Text "\n ")]
}),
#(Text "\n "),
#(Element:0x9a39cc {
name = "gitHubAuthId",
children = [ #(Text "3789877c-3eaa-4cce-8183-df16e9443bb1")]
}),
#(Text "\n "),
#(Element:0x9996e8 { name = "triggerPhrase" }),
#(Text "\n "),
#(Element:0x998ab8 {
name = "skipBuildPhrase",
children = [ #(Text ".
\[skip\W+ci\].
")]
}),
#(Text "\n "),
#(Element:0x987844 { name = "blackListCommitAuthor" }),
#(Text "\n "),
#(Element:0x986b74 { name = "blackListLabels" }),
#(Text "\n "),
#(Element:0x98600c { name = "whiteListLabels" }),
#(Text "\n "),
#(Element:0x97935c { name = "includedRegions" }),
#(Text "\n "),
#(Element:0x9787cc { name = "excludedRegions" }),
#(Text "\n "),
#(Element:0x975d24 {
name = "extensions",
children = [
#(Text "\n "),
#(Element:0x975388 {
name = "org.jenkinsci.plugins.ghprb.extensions.status.GhprbSimpleStatus",
children = [
#(Text "\n "),
#(Element:0x974974 { name = "commitStatusContext" }),
#(Text "\n "),
#(Element:0x971d50 { name = "triggeredStatus" }),
#(Text "\n "),
#(Element:0x97151c { name = "startedStatus" }),
#(Text "\n "),
#(Element:0x970d24 { name = "statusUrl" }),
#(Text "\n "),
#(Element:0x9704dc {
name = "addTestResults",
children = [ #(Text "false")]
}),
#(Text "\n ")]
}),
#(Text "\n ")]
}),
#(Text "\n ")]
}),
#(Text "\n ")]
}),
#(Text "\n ")]
})
}
definition {
cps {
script('''
node {
def mvnHome
stage('Preparation') { // for display purposes
// Get some code from a GitHub repository
git 'https://github.com/jglick/simple-maven-project-with-tests.git'
// Get the Maven tool.
// ** NOTE: This 'M3' Maven tool must be configured
// ** in the global configuration.

  }
  stage('Build') {
  // Run the maven build
  if (isUnix()) {
  sh "'mvn' -Dmaven.test.failure.ignore clean package"
  } else {
  bat(/"mvn" -Dmaven.test.failure.ignore clean package/)
  }
  }
  stage('Results') {
  junit '**/target/surefire-reports/TEST-*.xml'
  archive 'target/*.jar'
  }
  }

'''
)
sandbox(true)
}
}
triggers {
}
#(Element:0x96e628 { name = "disabled", children = [ #(Text "false")] })
}

@visualphoenix
Copy link
Owner

can you please let me know what the source xml job looks like and show me how you're invoking it?

sbuisson added a commit to sbuisson/jenkins-xml-to-jobdsl that referenced this issue Sep 13, 2017
@sbuisson
Copy link
Author

I cannot past xml properly, so I do a PR : #43

@visualphoenix
Copy link
Owner

visualphoenix commented Sep 14, 2017 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants