This file is indexed.

/usr/share/calibre/editor-functions.json is in calibre 2.75.1+dfsg-1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
{
    "Capitalize text (ignore tags)": "from calibre.utils.icu import capitalize\nfrom calibre.ebooks.oeb.polish.utils import apply_func_to_html_text\n\ndef replace(match, number, file_name, metadata, dictionaries, data, functions, *args, **kwargs):\n    '''Capitalize matched text, ignoring the text inside tag definitions.'''\n    return apply_func_to_html_text(match, capitalize)\n", 
    "Lower-case text (ignore tags)": "from calibre.utils.icu import lower\nfrom calibre.ebooks.oeb.polish.utils import apply_func_to_html_text\n\ndef replace(match, number, file_name, metadata, dictionaries, data, functions, *args, **kwargs):\n    '''Make matched text lower case, ignoring the text inside tag definitions.'''\n    return apply_func_to_html_text(match, lower)\n", 
    "Upper-case text (ignore tags)": "from calibre.utils.icu import upper\nfrom calibre.ebooks.oeb.polish.utils import apply_func_to_html_text\n\ndef replace(match, number, file_name, metadata, dictionaries, data, functions, *args, **kwargs):\n    '''Make matched text upper case, ignoring the text inside tag definitions.'''\n    return apply_func_to_html_text(match, upper)\n", 
    "Swap the case of text": "from icu import swap_case\nfrom calibre.ebooks.oeb.polish.utils import apply_func_to_match_groups\n\ndef replace(match, number, file_name, metadata, dictionaries, data, functions, *args, **kwargs):\n    '''Swap the case of the matched text. If the regular expression contains groups,\n    only the text in the groups will be changed, otherwise the entire text is\n    changed.'''\n    return apply_func_to_match_groups(match, swapcase)\n", 
    "Title-case text": "from calibre.utils.titlecase import titlecase\nfrom calibre.ebooks.oeb.polish.utils import apply_func_to_match_groups\n\ndef replace(match, number, file_name, metadata, dictionaries, data, functions, *args, **kwargs):\n    '''Title-case matched text. If the regular expression contains groups,\n    only the text in the groups will be changed, otherwise the entire text is\n    changed.'''\n    return apply_func_to_match_groups(match, titlecase)\n", 
    "Lower-case text": "from calibre.utils.icu import lower\nfrom calibre.ebooks.oeb.polish.utils import apply_func_to_match_groups\n\ndef replace(match, number, file_name, metadata, dictionaries, data, functions, *args, **kwargs):\n    '''Make matched text lower case. If the regular expression contains groups,\n    only the text in the groups will be changed, otherwise the entire text is\n    changed.'''\n    return apply_func_to_match_groups(match, lower)\n", 
    "Capitalize text": "from calibre.utils.icu import capitalize\nfrom calibre.ebooks.oeb.polish.utils import apply_func_to_match_groups\n\ndef replace(match, number, file_name, metadata, dictionaries, data, functions, *args, **kwargs):\n    '''Capitalize matched text. If the regular expression contains groups,\n    only the text in the groups will be changed, otherwise the entire text is\n    changed.'''\n    return apply_func_to_match_groups(match, capitalize)\n", 
    "Title-case text (ignore tags)": "from calibre.utils.titlecase import titlecase\nfrom calibre.ebooks.oeb.polish.utils import apply_func_to_html_text\n\ndef replace(match, number, file_name, metadata, dictionaries, data, functions, *args, **kwargs):\n    '''Title-case matched text, ignoring the text inside tag definitions.'''\n    return apply_func_to_html_text(match, titlecase)\n", 
    "Swap the case of text (ignore tags)": "from icu import swap_case\nfrom calibre.ebooks.oeb.polish.utils import apply_func_to_html_text\n\ndef replace(match, number, file_name, metadata, dictionaries, data, functions, *args, **kwargs):\n    '''Swap the case of the matched text, ignoring the text inside tag definitions.'''\n    return apply_func_to_html_text(match, swapcase)\n", 
    "Upper-case text": "from calibre.utils.icu import upper\nfrom calibre.ebooks.oeb.polish.utils import apply_func_to_match_groups\n\ndef replace(match, number, file_name, metadata, dictionaries, data, functions, *args, **kwargs):\n    '''Make matched text upper case. If the regular expression contains groups,\n    only the text in the groups will be changed, otherwise the entire text is\n    changed.'''\n    return apply_func_to_match_groups(match, upper)\n"
}