I am trying to replace the first six characters of a sub-tag <color></color> value in a KML file:
Current:
<Style id='1'>
        <LineStyle>
                <color>9900e6ff</color>
                <width>2</width>
        </LineStyle>
Expected:
<Style id='1'>
        <LineStyle>
                <color>ffffffff</color>
                <width>2</width>
        </LineStyle>
Attempted sed Code:
sed -i s/<LineStyle><color>[0-9]*</color></LineStyle>/<LineStyle><color>ffffff[0-9][a-z]</color></LineStyle>/g' file.kml
 
    