{"action":"created","issue":{"url":"https://api.github.com/repos/revelc/formatter-maven-plugin/issues/261","repository_url":"https://api.github.com/repos/revelc/formatter-maven-plugin","labels_url":"https://api.github.com/repos/revelc/formatter-maven-plugin/issues/261/labels{/name}","comments_url":"https://api.github.com/repos/revelc/formatter-maven-plugin/issues/261/comments","events_url":"https://api.github.com/repos/revelc/formatter-maven-plugin/issues/261/events","html_url":"https://github.com/revelc/formatter-maven-plugin/issues/261","id":276658801,"number":261,"title":"Running formatter:format goal in a multimodule project skips all submodules","user":{"login":"hea3ven","id":6192652,"avatar_url":"https://avatars1.githubusercontent.com/u/6192652?v=4","gravatar_id":"","url":"https://api.github.com/users/hea3ven","html_url":"https://github.com/hea3ven","followers_url":"https://api.github.com/users/hea3ven/followers","following_url":"https://api.github.com/users/hea3ven/following{/other_user}","gists_url":"https://api.github.com/users/hea3ven/gists{/gist_id}","starred_url":"https://api.github.com/users/hea3ven/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hea3ven/subscriptions","organizations_url":"https://api.github.com/users/hea3ven/orgs","repos_url":"https://api.github.com/users/hea3ven/repos","events_url":"https://api.github.com/users/hea3ven/events{/privacy}","received_events_url":"https://api.github.com/users/hea3ven/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":14,"created_at":"2017-11-24T16:18:07Z","updated_at":"2018-02-18T03:49:08Z","closed_at":null,"author_association":"NONE","body":"I've been trying to configure the formatter plugin for a multimodule project, the thing is that I don't want to integrate it to the project's lifecycle, I just want to be able to run it manually. The problem is that when I run `mvn formatter:format`, all the submodules are skipped and no formatting is done, if I instead run the goal in a specific project `mvn -pl <submodule id> formatter:format`, it works correctly.\r\n\r\nI've tried with a minimal project both, configuring formatter-maven-plugin in the parent pom, and configuring it in the children: [formatter-in-multimodule-project.zip](https://github.com/revelc/formatter-maven-plugin/files/1502135/formatter-in-multimodule-project.zip), with the following output:\r\n```$ mvn formatter:format\r\n[INFO] Scanning for projects...\r\n[INFO] ------------------------------------------------------------------------\r\n[INFO] Reactor Build Order:\r\n[INFO]\r\n[INFO] Multiproject Parent\r\n[INFO] Build Tools\r\n[INFO] Module A\r\n[INFO] Module B\r\n[INFO]\r\n[INFO] ------------------------------------------------------------------------\r\n[INFO] Building Multiproject Parent 1.0.0\r\n[INFO] ------------------------------------------------------------------------\r\n[INFO]\r\n[INFO] --- formatter-maven-plugin:2.7.1:format (default-cli) @ multiproject-parent ---\r\n[INFO] Using 'UTF-8' encoding to format source files.\r\n[INFO] Number of files to be formatted: 0\r\n[INFO] ------------------------------------------------------------------------\r\n[INFO] Reactor Summary:\r\n[INFO]\r\n[INFO] Multiproject Parent ................................ SUCCESS [  0.577 s]\r\n[INFO] Build Tools ........................................ SKIPPED\r\n[INFO] Module A ........................................... SKIPPED\r\n[INFO] Module B ........................................... SKIPPED\r\n[INFO] ------------------------------------------------------------------------\r\n[INFO] BUILD SUCCESS\r\n[INFO] ------------------------------------------------------------------------\r\n[INFO] Total time: 0.796 s\r\n[INFO] Finished at: 2017-11-24T13:00:34-03:00\r\n[INFO] Final Memory: 6M/155M\r\n[INFO] ------------------------------------------------------------------------\r\n```\r\n\r\nThe parent pom looks like this:\r\n\r\n```<?xml version=\"1.0\" encoding=\"UTF-8\"?>\r\n<project xmlns=\"http://maven.apache.org/POM/4.0.0\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"\r\n        xsi:schemaLocation=\"http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd\">\r\n\r\n        <modelVersion>4.0.0</modelVersion>\r\n\r\n        <groupId>com.example.multiproject</groupId>\r\n        <artifactId>multiproject-parent</artifactId>\r\n        <version>1.0.0</version>\r\n        <packaging>pom</packaging>\r\n        <name>Multiproject Parent</name>\r\n        <build>\r\n                <plugins>\r\n                        <plugin>\r\n                                <groupId>net.revelc.code.formatter</groupId>\r\n                                <artifactId>formatter-maven-plugin</artifactId>\r\n                                <version>2.7.1</version>\r\n                                <configuration>\r\n                                        <configFile>eclipse/kn_formatter.xml</configFile>\r\n                                        <encoding>UTF-8</encoding>\r\n                                </configuration>\r\n                                <dependencies>\r\n                                        <dependency>\r\n                                                <groupId>com.example.multiproject</groupId>\r\n                                                <artifactId>build-tools</artifactId>\r\n                                                <version>1.0.0</version>\r\n                                        </dependency>\r\n                                </dependencies>\r\n                        </plugin>\r\n                </plugins>\r\n        </build>\r\n        <modules>\r\n                <module>build-tools</module>\r\n                <module>moduleA</module>\r\n                <module>moduleB</module>\r\n        </modules>\r\n</project>```\r\n\r\nAm I doing something wrong, or is this use case not supported?"},"comment":{"url":"https://api.github.com/repos/revelc/formatter-maven-plugin/issues/comments/366490481","html_url":"https://github.com/revelc/formatter-maven-plugin/issues/261#issuecomment-366490481","issue_url":"https://api.github.com/repos/revelc/formatter-maven-plugin/issues/261","id":366490481,"user":{"login":"ctubbsii","id":1280725,"avatar_url":"https://avatars3.githubusercontent.com/u/1280725?v=4","gravatar_id":"","url":"https://api.github.com/users/ctubbsii","html_url":"https://github.com/ctubbsii","followers_url":"https://api.github.com/users/ctubbsii/followers","following_url":"https://api.github.com/users/ctubbsii/following{/other_user}","gists_url":"https://api.github.com/users/ctubbsii/gists{/gist_id}","starred_url":"https://api.github.com/users/ctubbsii/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ctubbsii/subscriptions","organizations_url":"https://api.github.com/users/ctubbsii/orgs","repos_url":"https://api.github.com/users/ctubbsii/repos","events_url":"https://api.github.com/users/ctubbsii/events{/privacy}","received_events_url":"https://api.github.com/users/ctubbsii/received_events","type":"User","site_admin":false},"created_at":"2018-02-18T03:49:07Z","updated_at":"2018-02-18T03:49:07Z","author_association":"OWNER","body":"@victornoel I suspect there's something else going on in your project. Do you have an example project which demonstrates the problem?"}}
{"actor":{"display_login":"ctubbsii"}}