PyCharm中创建文件模板

作者: monitor1379 | 来源:发表于2016-07-17 10:22 被阅读2277次

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

    # encoding: utf-8
    """
    @author: monitor1379 
    @contact: yy4f5da2@hotmail.com
    @site: www.monitor1379.com
    
    @version: 1.0
    @license: Apache Licence
    @file: ${NAME}.py
    @time: ${DATE} ${TIME}
    
    这一行开始写关于本文件的说明与解释
    """
    
    def run():
        pass
    
    if __name__ == '__main__':
        run()
    

    相关文章

      网友评论

        本文标题:PyCharm中创建文件模板

        本文链接:https://www.haomeiwen.com/subject/twgujttx.html