# HG changeset patch # User Augie Fackler # Date 2015-09-14 18:52:20 # Node ID 2bf152128d5937752e108e541e713b5fe2f0fd23 # Parent 85a2db47ad50b72194a8ffe86660fbc6c33bd5db makefile: add target to apply clang-format in-place This makes it easy to reformat files after you finish editing them. Differential Revision: https://phab.mercurial-scm.org/D1167 diff --git a/Makefile b/Makefile --- a/Makefile +++ b/Makefile @@ -122,6 +122,10 @@ testpy-%: check-code: hg manifest | xargs python contrib/check-code.py +format-c: + clang-format --style file -i \ + `hg files 'set:(**.c or **.h) and not "listfile:contrib/clang-format-blacklist"'` + update-pot: i18n/hg.pot i18n/hg.pot: $(PYFILES) $(DOCFILES) i18n/posplit i18n/hggettext