def line_count(file_path, include_blank_line=True) -> int:
    """
        计算单个文件中有多少行内容
        :param file_path:           文件路径
        :param include_blank_line:  计算中是否包含空行，默认包含
    """

    with open(file_path, 'r', encoding='utf8') as f:
        content = f.readlines()

        if include_blank_line:
            return len(content)

        content2 = [x for x in content if len(x.strip()) != 0]
        return len(content2)