PyCharm中创建文件模板

打开PyCharm IDE,进入File->settings->Editor->File and Code Templates->Python Script
添加以下内容:

# encoding: utf-8
"""
@author: monitor1379 
@contact: [email protected]
@site: www.monitor1379.com

@version: 1.0
@license: Apache Licence
@file: ${NAME}.py
@time: ${DATE} ${TIME}

这一行开始写关于本文件的说明与解释
"""

def run():
    pass

if __name__ == '__main__':
    run()

你可能感兴趣的:(PyCharm中创建文件模板)