zoukankan      html  css  js  c++  java
  • vim使用

    :%s/ / /gc    将空格替换为换行符

    :%s/ / /gc    将空格替换为制表符

    syntax on
    set ts=4
    set autoindent
    set smartindent
    set cindent shiftwidth=4
    set softtabstop=4
    autocmd FileType c set expandtab
    autocmd FileType cpp set expandtab
    autocmd FileType php set expandtab
    autocmd FileType python set expandtab
    set encoding=utf-8
    set fileencoding=utf-8
    set fileencodings=utf-8
    set is
    filetype plugin indent on

    ctrl + z 撤销恢复

    gg==G美化,前提有插件和vimrc中插件功能打开,注意文件后缀,否则无法识别

    删除空行    :g/^$/d    :g/^s*$/d
     
  • 相关阅读:
    126
    125
    124
    123
    122
    121
    120
    119
    洛谷 P5407 【[THUPC2019]历史行程】
    济南清北学堂七日游
  • 原文地址:https://www.cnblogs.com/bornfish/p/3800178.html
Copyright © 2011-2022 走看看