Here's some information:
http://www.history.navy.mil/browse-by-topic/heritage/customs-and-traditions/commissioning-pennant.html