The first fort on Sullivan's Island, constructed of palmetto logs and sand, was still incomplete when Commodore Sir Peter Parker of the Royal Navy and nine British men-of-war attacked it on June 28, 1776. After a nine-hour battle, the ships were forced to retire. Charlestown was saved from British occupation, and the fort was named in honor of its commander, Colonel William Moultrie. In May 1780 the British finally captured Charlestown, including Fort Moultrie, finally evacuating the city in December 1782 as the Revolution entered its final year.