VIM Advanced - PowerPoint PPT Presentation

1 / 15
About This Presentation
Title:

VIM Advanced

Description:

Much easy to use. Very easy to find from host. You can defined ... Indenting and Syntax highlighting :set autoindent :set smartindent :set cindent :syntax on : ... – PowerPoint PPT presentation

Number of Views:203
Avg rating:3.0/5.0
Slides: 16
Provided by: spa104
Category:

less

Transcript and Presenter's Notes

Title: VIM Advanced


1
VIM Advanced
  • eungkyu_at_sparcs
  • 2001. 5. 7.

2
Why VIM?
  • Easy to study
  • Much easy to use
  • Very easy to find from host
  • You can defined it for yourself
  • You can save time
  • Your hand will not be tired for long typing

3
Three Modes
  • Input mode
  • Command mode
  • ex mode

4
Basic
  • Motion
  • h, j, k, l, ,
  • w, W, b, B
  • -, , G, gg,
  • Delete - x, X, d, dd, D, J
  • Insert - a, A, i, I, o, O, r
  • Undo and Redo - u, o

5
Chage
  • Delete and Insert
  • r, R, c, cc, C, s, S,
  • Shift
  • lt, ltlt, gt, gtgt (shiftwidth)
  • Filter
  • !, !!, , (equalprg)
  • Regular Expressiong
  • s/pattern/string/modifier

6
Yank and Paste
  • Register, x
  • reg, y, yy, Y, p, P
  • Predefined registers
  • . - last inserted text
  • - current filename
  • - recent excuted command-line

7
Repeat
  • simple repeat - .
  • complex repeat
  • q0-9a-zA-Z
  • q
  • _at_0-9a-zA-Z
  • _at__at_

8
Remain
  • Visual v, V, ctrl-v
  • nu, sh, !cmd, !!, h

9
Compile and Error check
  • make execute makeprg
  • grep execute grepprg
  • Display error
  • cc nr nr or current error
  • cn next error
  • cp, cN previous error
  • cnf first error
  • cf nr nr or first error
  • cla nr nr or last error
  • cl list all error

10
Windows
  • sp, new, clo, on
  • ctrl w
  • j, k, t, b move to other window
  • r, R rotation
  • x exchange
  • -, , (res -N) resize
  • qa, wa

11
Indenting and Syntax highlighting
  • set autoindent
  • set smartindent
  • set cindent
  • syntax on
  • set syntaxperl
  • set backgrounddarklight

12
Various option
  • autowrite automatically write
  • fileencoding korea
  • fileformat dos, unix, mac
  • textwidth for writing mail
  • set tw78
  • autocmd see the example
  • help gzip-example

13
Tab size issue
  • First
  • set tabstop4
  • Second
  • set tabstop8
  • set softtabstop4
  • set shiftwidth4

14
Links
  • http//www.vim.org/

15
References
  • help
Write a Comment
User Comments (0)
About PowerShow.com