<commit_before>-module(disco).

-export([get_setting/1, is_resultfs_enabled/0]).

get_setting(SettingName) ->
    case os:getenv(SettingName) of
        false  ->
            exit(["Must specify ", SettingName]);
        Val ->
            Val
    end.

is_resultfs_enabled() ->
    lists:any(fun(X) ->
                  string:to_lower(X) == "resultfs"<commit_msg>output an error message to log if disco:get_setting() fails<commit_after>-module(disco).

-export([get_setting/1, is_resultfs_enabled/0]).

get_setting(SettingName) ->
    case os:getenv(SettingName) of
        false ->
            error_logger:warning_report(
                {"Required setting", SettingName, "missing!"}),
            exit(["Must specify ", SettingName]);
        Val ->
            Val
    end.

is_resultfs_enabled() ->
    lists:any(fun(X) ->
                  string:to_lower(X) == "resultfs"
{'fraction_non_alphanumeric': 0.13863636363636364, 'fraction_numerical': 0.004545454545454545, 'mean_word_length': 2.375478927203065, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 13, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7517059', 'n_tokens_mistral': 277, 'n_tokens_neox': 272, 'n_words': 48}