网络编程
位置:首页>> 网络编程>> Python编程>> Eclipse配置python默认头过程图解

Eclipse配置python默认头过程图解

作者:天天向上327  发布时间:2022-03-11 10:52:59 

标签:Eclipse,配置,python

eclipse 配置 python 默认头

打开eclipse 点 窗口(Windows)->首选项(Preferences)

Eclipse配置python默认头过程图解

Preferences窗口,点 PyDev --> Editor --> Templates,再点右上角的新建(New),进入新增模板窗口(New Template)

Eclipse配置python默认头过程图解

(New Template)" 窗口,name输入:pythonhead; Description输入:“注明文件编码,版本号,时间,作者” ; Pattern输入:

#!/usr/bin/python3
# encoding:utf-8
'''
Created on ${currentDate:date('yyyy-MM-dd HH:mm')}
@author: ${user}
'''

(Context)选“New Module",Automatically insert前打勾,输入选择完毕,点击“OK”

Eclipse配置python默认头过程图解

新建完成之后,返回Preferences窗口,点击“Apply and Close”按钮

Eclipse配置python默认头过程图解

回到主界面,新增新py文件

Eclipse配置python默认头过程图解

Eclipse配置python默认头过程图解

选择“pythonhead”,点击“OK”!

在这里插入图片描述

最终得到结果,新建的pythontest.py,头部位置默认有如下图内容

Eclipse配置python默认头过程图解

来源:https://www.cnblogs.com/yiwenrong/p/12731347.html

0
投稿

猜你喜欢

手机版 网络编程 asp之家 www.aspxhome.com