Last active
April 4, 2016 13:03
-
-
Save HeLiBloks/026da1fb5674b1659e9a989612a5f7af to your computer and use it in GitHub Desktop.
html table from csv file with sed
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
sed -re ' | |
s/^.*$/<tr>\n<td>&<\/td>\n<\/tr>/g | |
s/[,]/<\/td>\n<td>/g | |
1i <table style="width:100%"> | |
$a\<\/table>' "$1" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment