In the following string,
apache:x:48:48:Apache:/var/www:/sbin/nologin
how could I replace the first colon (and this one only) with a comma so I would get the following string?
apache,x:48:48:Apache:/var/www:/sbin/nologin
Also, the code has to support a file with multiple lines and replace the first comma in each line only.