elide javaformat formats Java source with Google Java Format.
Format files
elide javaformat -- Hello.java src/main/javaA normal invocation rewrites files in place. The standard replacement flags remain accepted for compatibility:
elide javaformat -- -i Hello.javaCheck formatting
Use -n or --dry-run after --. The command exits 1 when a file would
change:
elide javaformat -- -n src/main/javaElide adds two reporting options before --:
elide javaformat --list-files -- -n src/main/java
elide javaformat --list-diffs -- -n src/main/java
elide javaformat --list-diffs=5 -- -n src/main/java--list-diffs=N prints diffs only when at most N files fail; otherwise it
falls back to listing paths. Use =N, not a separate value.
To format Java and Kotlin in one command, use:
elide format -- src