I have a directory that is receiving .csv files.
column1,column2,column3,columb4
value1,0021,value3,value4,
value1,00211,value3,value4,
I want remove the header, pad the second column to 6 digits and add ":" so it is in HH:MM:SS format. e.g.
value1,00:00:21,value3,value4,
value1,00:02:11,value3,value4,
I can pad the characters to 6 digits using awk but I am not sure to insert the semicolumn every 2 characters for the second $2. Else can this be fully done in sed? which would be better for performance?
Thank you
00211is000211instead of002101?