<commit_before>:- module(html_resource, []).
:- reexport(library(http/html_head)).

/** <module> HTML resource

Initialize locations for serving HTML resources.

@author <NAME>
@version 2015/08, 2016/02
*/

:- use_module(library(http/http_dispatch)).
:- use_module(library(http/http_server_files)).

:- dynamic
    user:file_search_path/2,
    http:location/3.
:- multifile
    user:file_search_path/2,
    http:location/3.

user:file_search_path(css,  library(resource/css)).
user:file_search_path(font, library(resource/font)).
user:file_search_path(icon, library(resource/icon)).
user:file_search_path(img,  library(resource/img)).
user:file_search_path(js,   library(resource/js)).
user:file_search_path(pdf,  library(resource/pdf)).

http:location(css,  root(css),  []).
http:location(font, root(font), []).
http:location(icon, root(icon), []).
http:location(img,  root(img),  []).
http:location(js,   root(js),   []).
http:location(pdf,  root(pdf),  []).

:- http_handler(css(.),  serve_files_in_directory(css),  [prefix]).
:- http_handler(font(.), serve_files_in_directory(font), [prefix]).
:- http_handler(icon(.), serve_files_in_directory(icon), [prefix]).
:- http_handler(img(.),  serve_files_in_directory(img),  [prefix]).
:- http_handler(js(.),   serve_files_in_directory(js),   [prefix]).
:- http_handler(pdf(.),  serve_files_in_directory(pdf),  [prefix]).<commit_msg>FIXED: Bootstrap wants the directory to be called font[s].<commit_after>:- module(html_resource, []).
:- reexport(library(http/html_head)).

/** <module> HTML resource

Initialize locations for serving HTML resources.

@author <NAME>
@version 2015/08, 2016/02
*/

:- use_module(library(http/http_dispatch)).
:- use_module(library(http/http_server_files)).

:- dynamic
    user:file_search_path/2,
    http:location/3.
:- multifile
    user:file_search_path/2,
    http:location/3.

user:file_search_path(css,   library(resource/css)).
user:file_search_path(fonts, library(resource/fonts)).
user:file_search_path(icon,  library(resource/icon)).
user:file_search_path(img,   library(resource/img)).
user:file_search_path(js,    library(resource/js)).
user:file_search_path(pdf,   library(resource/pdf)).

http:location(css,   root(css),   []).
http:location(fonts, root(fonts), []).
http:location(icon,  root(icon),  []).
http:location(img,   root(img),   []).
http:location(js,    root(js),    []).
http:location(pdf,   root(pdf),   []).

:- http_handler(css(.),   serve_files_in_directory(css),   [prefix]).
:- http_handler(fonts(.), serve_files_in_directory(fonts), [prefix]).
:- http_handler(icon(.),  serve_files_in_directory(icon),  [prefix]).
:- http_handler(img(.),   serve_files_in_directory(img),   [prefix]).
:- http_handler(js(.),    serve_files_in_directory(js),    [prefix]).
:- http_handler(pdf(.),   serve_files_in_directory(pdf),   [prefix]).
{'fraction_non_alphanumeric': 0.1832276250880902, 'fraction_numerical': 0.01127554615926709, 'mean_word_length': 5.68, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, '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': '4526242', 'n_tokens_mistral': 1008, 'n_tokens_neox': 980, 'n_words': 141}