xgqfrms™, xgqfrms® : xgqfrms's offical website of cnblogs! xgqfrms™, xgqfrms® : xgqfrms's offical website of GitHub!

Pycharm 如何自定义新建的 Python 文件的注释模版 All in One

Pycharm 如何自定义新建的 Python 文件的注释模版 All in One

Python code template


#!/usr/bin/env python3

# coding=utf-8

__author__ = 'xgqfrms'
__editor__ = 'vscode'
__version__ = '1.0.1'
__copyright__ = """
  Copyright (c) 2012-2050, xgqfrms; mailto:xgqfrms@xgqfrms.xyz
"""

"""
  /**
   * 
   * @author xgqfrms
   * @license MIT
   * @copyright xgqfrms
   * @created 2020-08-0
   * 
   * @description 
   * @augments 
   * @example 
   * @link 
   * 
  */
"""

print('py3 code template 🐍')

print('人生苦短,我用拍三 🐍')

# python3 ./py3.py

test

$ python3 ./py3.py

# py3 code template 🐍
# 人生苦短,我用拍三 🐍

Python 3 === 拍三 3

文件头注释

设置路径:Preferences => File and Code Templates > Python Script

快捷键: command + , 搜索 template 即可 ✅

Pycharm Community Version 🐍

https://www.jetbrains.com/zh-cn/pycharm/download/#section=mac

https://www.jetbrains.com/zh-cn/pycharm/download/download-thanks.html?platform=mac&code=PCC

refs

https://github.com/xgqfrms/vscode/blob/master/code-snippets/py3.json



©xgqfrms 2012-2025

www.cnblogs.com/xgqfrms 发布文章使用:只允许注册用户才可以访问!

原创文章,版权所有©️xgqfrms, 禁止转载 🈲️,侵权必究⚠️!


posted @   xgqfrms  阅读(229)  评论(1编辑  收藏  举报
相关博文:
阅读排行:
· 被坑几百块钱后,我竟然真的恢复了删除的微信聊天记录!
· 【自荐】一款简洁、开源的在线白板工具 Drawnix
· 没有Manus邀请码?试试免邀请码的MGX或者开源的OpenManus吧
· 园子的第一款AI主题卫衣上架——"HELLO! HOW CAN I ASSIST YOU TODAY
· 无需6万激活码!GitHub神秘组织3小时极速复刻Manus,手把手教你使用OpenManus搭建本
历史上的今天:
2021-08-17 Apple Watch Series 6 开启自带 GPS All In One
2021-08-17 element-ui & async-validator bug All In One
2021-08-17 element-ui & multi tabs bug All In One
2020-08-17 LeetCode & linked list
2020-08-17 how to install GitLab on Raspberry Pi OS
2020-08-17 UML online tools
2020-08-17 React Hooks 内部实现原理
点击右上角即可分享
微信分享提示