1. 点击文件→首选项→配置用户代码片段
2. 框中输入python
如果第一次设置输入python显示python(Python), 之前选择过会出现python.json(Python),不管哪种点击就行
进入python.json后,按需更改自己想显示的信息就行
例如:
{
"HEADER": {
"prefix": "header",
"body": [
"#!/usr/bin/env python",
"# -*- encoding: utf-8 -*-",
"'''",
"@File : $TM_FILENAME",
"@Time : $CURRENT_YEAR/$CURRENT_MONTH/$CURRENT_DATE $CURRENT_HOUR:$CURRENT_MINUTE:$CURRENT_SECOND",
"@Author : zhangsan ",
"@Email : zhangsan@xxxxxxx",
"@description : xxxxxxxxx",
"'''",
"",
],
}
}
在新建py文件中输入header,就会出现设置的头部信息