I want to take a file that has a list of words on each line of its own eg.
act
bat
cat
dog
eel
and put them into one line with comma separated and quoting them. So that it turns out like:
'act', 'bat', 'cat', 'dog', 'eel',
so, a single quote, then the word, then another single quote, then a comma, then a space. Then output to a new file with a new name.
awk -vq=\' '{printf q"%s"q", ", $0}'
etc somewhat like Sergiy's perl answer – dave_thompson_085 Oct 23 '17 at 09:55