Skip to content

Prefix #40

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Feb 29, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -42,13 +42,13 @@ Add this to your maven project **root** pom.xml :
### Manual code formatting

```console
mvn git-code-format:format-code -DglobPattern=**/*
mvn git-code-format:format-code -Dgcf.globPattern=**/*
```

### Manual code format validation

```console
mvn git-code-format:validate-code-format -DglobPattern=**/*
mvn git-code-format:validate-code-format -Dgcf.globPattern=**/*
```

### Google Java Format options
Original file line number Diff line number Diff line change
@@ -19,7 +19,7 @@
*/
public abstract class AbstractFormatMojo extends AbstractModulMavenGitCodeFormatMojo {

@Parameter(property = "globPattern", required = true, defaultValue = "**/*")
@Parameter(property = "gcf.globPattern", required = true, defaultValue = "**/*")
private String globPattern;

@Override
Original file line number Diff line number Diff line change
@@ -19,10 +19,10 @@ public abstract class AbstractModulMavenGitCodeFormatMojo extends AbstractMavenG
@Parameter(property = "gcf.skip", defaultValue = "false")
private boolean skip;

@Parameter(property = "includedModules")
@Parameter(property = "gcf.includedModules")
private List<String> includedModules;

@Parameter(property = "excludedModules")
@Parameter(property = "gcf.excludedModules")
private List<String> excludedModules;

/** @return True if the goal is enabled for the current module */
10 changes: 5 additions & 5 deletions src/main/java/com/cosium/code/format/InstallHooksMojo.java
Original file line number Diff line number Diff line change
@@ -43,22 +43,22 @@ public class InstallHooksMojo extends AbstractMavenGitCodeFormatMojo {
* True to truncate hooks base scripts before each install. <br>
* Do not use this option if any other system or human manipulate the hooks
*/
@Parameter(property = "truncateHooksBaseScripts", defaultValue = "false")
@Parameter(property = "gcf.truncateHooksBaseScripts", defaultValue = "false")
private boolean truncateHooksBaseScripts;

/** The list of properties to propagate to the hooks */
@Parameter(property = "propertiesToPropagate")
@Parameter(property = "gcf.propertiesToPropagate")
private String[] propertiesToPropagate;

/** The list of properties to add to the hooks */
@Parameter(property = "propertiesToAdd")
@Parameter(property = "gcf.propertiesToAdd")
private String[] propertiesToAdd;

@Parameter(property = "debug", defaultValue = "false")
@Parameter(property = "gcf.debug", defaultValue = "false")
private boolean debug;

/** Add pipeline to process the results of the pre-commit hook. Exit non-zero to prevent the commit */
@Parameter(property = "preCommitHookPipeline", defaultValue = "")
@Parameter(property = "gcf.preCommitHookPipeline", defaultValue = "")
private String preCommitHookPipeline;

public void execute() throws MojoExecutionException {