-
Notifications
You must be signed in to change notification settings - Fork 7.5k
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
Add format options for stdout from Execute Command nodes #58
Comments
Very sorry for getting back to this so late! Please post all further questions to: There are actualy already new line "\n" characters in the response. Only the UI does not display them in the view (as \n does not create a new line in HTML). But as soon as you use them in an expression you will see that it works like in this example: {
"nodes": [
{
"parameters": {
"command": "ls "
},
"name": "Execute Command",
"type": "n8n-nodes-base.executeCommand",
"typeVersion": 1,
"position": [
430,
300
]
},
{
"parameters": {
"values": {
"string": [
{
"name": "files",
"value": "={{$node[\"Execute Command\"].data[\"stdout\"]}}"
}
]
}
},
"name": "Set",
"type": "n8n-nodes-base.set",
"typeVersion": 1,
"position": [
580,
300
]
}
],
"connections": {
"Execute Command": {
"main": [
[
{
"node": "Set",
"type": "main",
"index": 0
}
]
]
}
}
} Really have to find a proper solution that the newline characters get displayed also in the UI! |
Ok just pushed a "fix": It uses now a different library for the JSON data. That one displays now new-lines correctly. Will be released with the next n8n version. |
Hi,
Let's say I have a home directory with three files named "test1", "test2", and "test3" and I add an Execute Command node with the command as "ls ~". The stdout as of now will be one line as "test1 test2 test3". Not sure if this by design or not. Can an option be added to put the output on separate lines or honor UNIX newlines. So would like output to be like:
test1
test2
test3
Thanks to the developer. Liking this project so far BTW .
The text was updated successfully, but these errors were encountered: