All Downloads are FREE. Search and download functionalities are using the official Maven repository.

htmlcompiler.commands.Dependencies Maven / Gradle / Ivy

There is a newer version: 5.8.0
Show newest version
package htmlcompiler.commands;

import htmlcompiler.tools.Logger;

import java.io.FileNotFoundException;

import static htmlcompiler.tools.IO.findBinaryInPath;

public enum Dependencies {;

    public static void executeDependencies(final Logger log) {
        testExistenceBinary(log, "TypeScript compiler", "tsc");
        testExistenceBinary(log, "Dart compiler", "dart2js");
        testExistenceBinary(log, "JS++ compiler", "js++");
        testExistenceBinary(log, "Stylus compiler", "stylus");
        testExistenceBinary(log, "Sass/Scss compiler", "sass");
    }

    private static void testExistenceBinary(final Logger log, final String name, final String binary) {
        try {
            findBinaryInPath(binary);
        } catch (FileNotFoundException e) {
            log.warn("Unable to find the " + name + ". Binary name is " + binary);
        }
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy