Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Transform a file of lines into a pythonic-list of comma delimited strings on the command line
cat old_db_tables.list.txt |sed -e 's/^/"/;s/$/"/'| tr '\n' ','|sed 's/^/[/;s/$/]/'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment