wh dev::rewrite <file> cleans up XML for supported filetypes (eg siteprofiles) and can even clear up some deprecated constructs.
wh dev:cleanup executes a cleanup on a folder or an entire module
wh dev:rewrite can also rewite siteprofiles to the 'simpler' syntax enabled by WebHare 4.28 (eg simplified filetypes with kind= and embedded members). To opt-in to this rewrite your module must explicitly declare that it won't support older WebHare versions, eg by setting webhareversion=">= 4.28.0-dev" on its packaging node:
<packaging download="true" webhareversion=">= 4.28.0-dev">