V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
爱意满满的作品展示区。
guyskk
V2EX  ›  分享创造

分享一个格式化 Python 代码的 Atom [插件的插件]

  •  1
     
  •   guyskk ·
    guyskk · 2017-04-17 22:56:41 +08:00 · 2792 次点击
    这是一个创建于 2536 天前的主题,其中的信息可能已经有所发展或是发生改变。

    https://github.com/Glavin001/atom-beautify 增加了一个 pybeautifier 格式化器,通过 TCP server 来格式化代码,执行的时候不需要创建新进程,所以速度比原来的 autopep8 和 yapf 快很多。

    PR 在这: https://github.com/Glavin001/atom-beautify/pull/1330 ,昨天刚合并,自己用了好几个月了
    Server 代码在这: https://github.com/guyskk/pybeautifier

    快速上手:

    1. 安装 atom-beautify ,并选择 pybeautifier 作为默认格式化器
    2. pip3 install pybeautifier autopep8
    3. 启动 Server: pybeautifier 或者 pybeautifier -d (后台进程)
    目前尚无回复
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   3293 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 32ms · UTC 11:29 · PVG 19:29 · LAX 04:29 · JFK 07:29
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.