<commit_before>#!/usr/bin/env python
#-*- coding: utf-8 -*-

# 1. Copyright
# 2. Lisence
# 3. Author

"""
Documents
"""

from __future__ import absolute_import
from __future__ import print_function
from __future__ import division
from __future__ import unicode_literals

import os

from . import sys_info


def list_win_volume():
    vol_list = []
    for label in range(67, 90):
        vol = chr(label) + ':\\'
        if os.path.isdir(vol):
            vol_list.append(vol)
    return vol_list


def list_os_root_path():
    root_list = []
    home_path = os.getenv('HOME')
    os_name = sys_info.get_os_name()
    if os_name == 'windows':
        root_list = list_win_volume()
    elif os_name == 'osx':
        root_list = [home_path, '/Applications']
    else:
        root_list = [home_path, '/usr', '/opt']
    return root_list


def list_user_root_path():
    root_list = []
    os_name = sys_info.get_os_name()
    if os_name == 'windows':
        root_list = list_win_volume()
    else:
        home_path = os.getenv('HOME')
        root_list = [home_path]
    return root_list


def get_document_path():
    os_name = sys_info.get_os_name()
    if os_name == 'windows':
        python_version = sys_info.get_python_version()
        if python_version < 3:
            import _winreg as winreg<commit_msg>Add root dir.<commit_after>#!/usr/bin/env python
#-*- coding: utf-8 -*-

# 1. Copyright
# 2. Lisence
# 3. Author

"""
Documents
"""

from __future__ import absolute_import
from __future__ import print_function
from __future__ import division
from __future__ import unicode_literals

import os

from . import sys_info


def list_win_volume():
    vol_list = []
    for label in range(67, 90):
        vol = chr(label) + ':\\'
        if os.path.isdir(vol):
            vol_list.append(vol)
    return vol_list


def list_os_root_path():
    root_list = []
    home_path = os.getenv('HOME')
    os_name = sys_info.get_os_name()
    if os_name == 'windows':
        root_list = list_win_volume()
    elif os_name == 'osx':
        root_list = [home_path, '/Applications', '/']
    else:
        root_list = [home_path, '/usr', '/opt', '/']
    return root_list


def list_user_root_path():
    root_list = []
    os_name = sys_info.get_os_name()
    if os_name == 'windows':
        root_list = list_win_volume()
    else:
        home_path = os.getenv('HOME')
        root_list = [home_path, '/']
    return root_list


def get_document_path():
    os_name = sys_info.get_os_name()
    if os_name == 'windows':
        python_version = sys_info.get_python_version()
        if python_version < 3:
            import _winreg as winreg
{'fraction_non_alphanumeric': 0.11900264450321119, 'fraction_numerical': 0.00680015111446921, 'mean_word_length': 2.7507082152974505, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 3, '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': '3496501', 'n_tokens_mistral': 931, 'n_tokens_neox': 898, 'n_words': 211}