private static void runCommand()

in src/main/java/software/amazon/smithy/plugin/SmithyPostStartupActivity.java [175:189]


    private static void runCommand(List<String> command) {
        ProcessBuilder builder = new ProcessBuilder(command);
        try {
            Process proc = builder.start();
            proc.waitFor();
            proc.destroy();
            // Throw a runtime error if the Coursier command failed.
            if (proc.exitValue() != 0) {
                throw new RuntimeException("Coursier command returned non-zero");

            }
        } catch (IOException | InterruptedException e) {
            throw new RuntimeException(e);
        }
    }