Describe the issue/error/question
I have file downloaded from s3 bucket , which contains my project dependency names , the problem the file is shabby with random format with various characters between each dependency names . I would want each names in the file to come in separate rows for the next node (preferably as array of keywords)
What is the error message (if any)?
I am able to split the file identifying one kind of pattern to split each names , the problem is after certain point the pattern changes.
Please share the workflow
Finally the names in dependency file must appear as array of names for the next node
Currently my last node is “code node” where I am using simple 2 lines as below.
items[0].json.data = items[0].json.data.split(“(n)\n±–”);
return items;
which works perfectly for names matching above pattern.
Further I do have the need to split names having multiple types of above such various characters. Example being (c)\n| | | | | | | ±-- , (*)\n| | | | | -–
How do I achieve this with code node .
(Select the nodes and use the keyboard shortcuts CMD+C/CTRL+C and CMD+V/CTRL+V to copy and paste the workflow respectively)
Share the output returned by the last node
Information on your n8n setup
- n8n version:
- Database you’re using (default: SQLite):
- Running n8n with the execution process [own(default), main]:
- Running n8n via [Docker, npm, n8n.cloud, desktop app]: