UnisKB/apps/common/util/file_util.py

17 lines
279 B
Python
Raw Blame History

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

# coding=utf-8
"""
@project: maxkb
@Author
@file file_util.py
@date2023/9/25 21:06
@desc:
"""
def get_file_content(path):
file = open(path, "r",
encoding='utf-8')
content = file.read()
file.close()
return content