回到顶部

阅读目录

pycharm 默认模版 File and Code Templates

pycharm 默认的【新建】文件,格式想指定自己的一些信息,比如:编码、自己的信息、新建时间等,那么就需要改一下文件模板。

具体步骤是(我这里是 专业版,社区版未知):

1.【File】-->【Settings...】,打开设置界面

2. 在搜索框处,输入 File

3. 然后在搜出来的结果处,点击【File and Code Templates】,选择对应要建立的文件,之后就可以改新建文件的模板了

# example

#!/usr/bin/env python3
# -*- coding: utf-8 -*-

"""
@author: yinzhuoqun
@site: http://zhuoqun.info/
@email: yin@zhuoqun.info
@time: ${DATE} ${TIME}
"""

# 效果

#!/usr/bin/env python3
# -*- coding: utf-8 -*-

"""
@author: yinzhuoqun
@site: http://zhuoqun.info/
@email: yin@zhuoqun.info
@time: 2019/4/22 15:22
"""

 

^_^
请喝咖啡 ×

文章部分资料可能来源于网络,如有侵权请告知删除。谢谢!

前一篇: django runserver: UnicodeDecodeError: 'utf-8' codec can't decode byte 0xb6 in position 0: invalid start byte
下一篇: django admin 给 字段 增加 HTML 样式(显示图片、设置字体颜色、超链接、按钮等)
captcha