You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by kw...@apache.org on 2022/11/30 07:57:49 UTC

[maven-parent] branch feature/document-format-profile created (now 5243bac)

This is an automated email from the ASF dual-hosted git repository.

kwin pushed a change to branch feature/document-format-profile
in repository https://gitbox.apache.org/repos/asf/maven-parent.git


      at 5243bac  [MPOM-370] Document "format" profile

This branch includes the following new commits:

     new 5243bac  [MPOM-370] Document "format" profile

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.



[maven-parent] 01/01: [MPOM-370] Document "format" profile

Posted by kw...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

kwin pushed a commit to branch feature/document-format-profile
in repository https://gitbox.apache.org/repos/asf/maven-parent.git

commit 5243bac0e4956a9454e7f1c66c0d29d6bde3931f
Author: Konrad Windszus <kw...@apache.org>
AuthorDate: Wed Nov 30 08:57:42 2022 +0100

    [MPOM-370] Document "format" profile
---
 src/site-docs/apt/index.apt.vm | 11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/src/site-docs/apt/index.apt.vm b/src/site-docs/apt/index.apt.vm
index d6a5e2d..ec0ffc3 100644
--- a/src/site-docs/apt/index.apt.vm
+++ b/src/site-docs/apt/index.apt.vm
@@ -56,6 +56,17 @@ mvn -Preporting site
     This POM provides <<<jdk-toolchain>>> profile to activate JDK selection as a toolchain with version
     requirement configured as minimum java version for the project.
 
+* The <<<format>>> Profile
+
+    Since version 38 the <<<format>>> profile can be used to explicitly format source files with
+    {{{https://github.com/diffplug/spotless/tree/main/plugin-maven}spotless-maven-plugin}} according to 
+    {{{/developers/conventions/code.html}Maven standards}}.
+    This requires the phase {{{/guides/introduction/introduction-to-the-lifecycle.html#default-lifecycle}process-sources}}.
+    After applying bigger reformatting it is recommended to add or update a <<<.git-blame-ignore-revs>>> file in the root of the repository
+    containing a line with the SHA1 of the formatting commit to ignore those changes when using blame.
+    This is automatically considered by {{{https://docs.github.com/en/repositories/working-with-files/using-files/viewing-a-file#bypassing-git-blame-ignore-revs-in-the-blame-view}GitHub}}
+    and can optionally be considered with {{{https://git-scm.com/docs/git-blame#Documentation/git-blame.txt---ignore-revs-fileltfilegt}local <<<git blame>>>}}
+
 * Site Publication
 
     This POM prepares site publication to {{{/developers/website/index.html}Apache Maven's site svnpubsub}}.