private static Map<String, Object> loadProperties(final String filePath) throws Exception {
        val properties = new Properties();
        try (val input = new FileInputStream(filePath)) {
            properties.load(input);

            val groupedProperties = new TreeMap<String, Object>();
            for (val key : properties.stringPropertyNames()) {
                addToGroupedProperties(groupedProperties, key, properties.getProperty(key));
            }
            return groupedProperties;
        }
    }
Convert properties to YAML.

@param propertiesFile the properties file
@throws Exception the exception
support/cas-server-support-shell-core/src/main/java/org/apereo/cas/shell/commands/properties/ConvertPropertiesToYAMLCommand.java