Tidy up and document plugins