jenkinsci / jenkinsci/durable-task-plugin
[JENKINS-56925] extra newline character from powershell output
- Dominant language
- Java
- Stars
- 30
- Forks
- 101
- PR merge metrics
- No merged PRs in 30d
Description
When i trying to wrap some powershell script output into variable, it's adds excess \n symbol to.
Like:
script {
VARI = powershell (returnStdout: true, script: """Write-Output foo""")
println VARI
}
It's outputs the following:
[Pipeline] script
[Pipeline] {
[Pipeline] powershell
[Pipeline] echo
foo[Pipeline] }
[Pipeline] // script
[Pipeline] }
But powershell itself transmits output without `n .
How to escape it in output?
---
Originally reported by gek, imported from: extra newline character from powershell output
Raw content of original issue
When i trying to wrap some powershell script output into variable, it's adds excess \n symbol to.
Like:
script {
VARI = powershell (returnStdout: true, script: """Write-Output foo""")
println VARI
}It's outputs the following:
[Pipeline] script
[Pipeline] {
[Pipeline] powershell
[Pipeline] echo
foo[Pipeline] }
[Pipeline] // script
[Pipeline] }But powershell itself transmits output without `n .
How to escape it in output?
environment
```
Jenkins ver. 2.164.1
Durable Task Plugin 1.29
```
Contributor guide
Assessment
This issue has not been assessed yet.