• 请不要在回答技术问题时复制粘贴 AI 生成的内容
lcj2class
V2EX  ›  程序员

大家平时 coding 时都收藏了哪些提高效率的小工具

  •  1
     
  •   lcj2class · May 6, 2018 via Android · 7717 views
    This topic created in 2946 days ago, the information mentioned may be changed or developed.

    我先说个我的情况

    相信大家平时都会与时间戳打交道,debug 时经常需要把它格式化为人类可读的字符串,我之前一直是打来浏览器 console,然后 new Date(ts) 解决,偶尔也会找个在线工具来转,但这都需要离开之前的环境,不是很优雅。 直到今天我才意识到写一个 Emacs 函数就能搞定,哎,之前懒得不够彻底!

    Emacs 同学可参考: https://github.com/jiacai2050/dotfiles/blob/e649223ae94ba3365a45120fd867f5638ff20abd/.emacs.d/customizations/editing.el#L102-L116

    22 replies    2018-05-07 18:36:43 +08:00
    seaswalker
        1
    seaswalker  
       May 6, 2018 via iPhone   ❤️ 4
    我是用 Linux 命令,date -d @时间戳
    crb912
        2
    crb912  
       May 6, 2018 via Android
    文件搜索
    catfish(linux 平台),everything(win 平台)
    从此告别在文件夹下面一个找文件。
    jssyxzy
        3
    jssyxzy  
       May 6, 2018
    linux , date
    xio
        4
    xio  
       May 6, 2018 via Android   ❤️ 1
    peco
    lxml
        5
    lxml  
       May 6, 2018
    因为 mac 上 bsd 和 linux 上 GNU 命令行风格不同,总记不住,我是写了个简单 bash 函数封装了下。
    # mac
    tim(){
    date -r ${1}
    }

    # linux
    tim(){
    date -d @${1}
    }

    用的时候 无脑 $ tim 1525588495
    willakira
        6
    willakira  
       May 6, 2018
    autojump
    shiny
        7
    shiny  
    PRO
       May 6, 2018
    一次函数调用的事情,这种场景我用 CodeRunner
    scnace
        8
    scnace  
       May 6, 2018 via Android
    我用 Alfred Workflow(
    0xCNSumi
        9
    0xCNSumi  
       May 6, 2018
    sublime 的正则查找和替换
    listray 比 everything 好用和好看不要太多
    totalcommander 浏览目录
    date -d @{时间戳}
    base64 --d
    最常用的还是 alt+tab 切换窗口
    GoLand
        10
    GoLand  
       May 6, 2018
    autojump +1
    i730
        11
    i730  
       May 6, 2018
    乍一看以为是 coding 的广告
    wanderpoet
        12
    wanderpoet  
       May 6, 2018 via iPhone
    @gocnsumi #9 listray+1
    pompeii
        13
    pompeii  
       May 6, 2018 via iPhone
    改键?什么左右、首尾、或者按单词移动光标,还有对应的删除,都改到主键区(不会用 vim )
    lcj2class
        14
    lcj2class  
    OP
       May 6, 2018 via Android
    @pompeii 你在说什么?是说我 Emacs 里的配置嘛?那是因为终端下的 Emacs 有些快捷键无法直接输入,被终端捕获了。
    xxstop
        15
    xxstop  
       May 6, 2018
    alfred
    opengps
        16
    opengps  
       May 6, 2018 via Android
    我说一个快捷键吧,很实用但是很多人不知道的。
    同时编辑多列,alt+鼠标竖向选中,输入或者粘贴。
    这时候对于规则的多行编辑很管用,这一招经常用在拼写 SQL 的 in 语句时候,把复制出来的列前后加上',' 再用正则清空掉换行标记
    asaxing
        17
    asaxing  
       May 7, 2018   ❤️ 1
    命令行中格式化 JSON 数据:curl xxx | python -m json.tool
    siteshen
        18
    siteshen  
       May 7, 2018   ❤️ 1
    ;; 我通常用的这个 https://www.epochconverter.com/
    ;; 如果只需要查看,可以用更简单的函数
    (format-time-string "%FT%T%z" (number-at-point))

    ;; (describe-function 'format-time-string)
    ;; For example, to produce full ISO 8601 format, use "%FT%T%z".
    arzterk
        19
    arzterk  
       May 7, 2018
    ripgrep
    remarrexxar
        20
    remarrexxar  
       May 7, 2018
    windows 平台 wox
    sc13
        21
    sc13  
       May 7, 2018
    经常用 snipaste 截屏软件,钉在桌面上用来看数据库字段或者一些刚才要记住的东西.
    alexwu
        22
    alexwu  
       May 7, 2018
    intellij 的 Custom Postfix Templates 插件
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   2802 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 86ms · UTC 09:57 · PVG 17:57 · LAX 02:57 · JFK 05:57
    ♥ Do have faith in what you're doing.