public static void verify()

in src/main/java/org/jetbrains/uncrustify/util/UncrustifyConfigFile.java [81:99]


    public static void verify(@NotNull String executablePath, @NotNull String configPath, @NotNull VerificationListener listener, boolean block) throws ExecutionException {
        UncrustifyExecutable.executeWithProcessListener(
                executablePath,
                List.of("-c", configPath, "-l", "JAVA"),
                JAVA_SNIPPET,
                new CapturingProcessAdapter() {
                    public void processTerminated(@NotNull ProcessEvent event) {
                        super.processTerminated(event);

                        int exitCode = event.getExitCode();
                        if (exitCode == 0) {
                            listener.onValid();
                        } else {
                            listener.onInvalid(getOutput().getStderr());
                        }
                    }
                },
                block);
    }