Various fixes

* Fix header and trailing lines
* Add missing keywords header
* Require 'cl at runtime, not compile-time, for delete-duplicates
* Only use `' quoting for lisp symbols
* More closely follow checkdoc guidelines for docstrings
* Add missing defvar for command history