무료 변환기

Vim 명령 치트 시트

포괄적인 Vim 명령 치트 시트. 예제, 설명 및 원클릭 복사를 통해 80개 이상의 필수 Vim 명령을 검색하세요.

i
Enter Insert mode before the cursor
예:i
I
Enter Insert mode at the beginning of the line
예:I
a
Enter Insert mode after the cursor
예:a
A
Enter Insert mode at the end of the line
예:A
o
Open a new line below and enter Insert mode
예:o
O
Open a new line above and enter Insert mode
예:O
v
Enter Visual mode (character selection)
예:v
V
Enter Visual Line mode (line selection)
예:V
Ctrl+v
Enter Visual Block mode (column selection)
예:Ctrl+v
:
Enter Command-line mode
예::w
Esc
Return to Normal mode from any mode
예:Esc
R
Enter Replace mode (overwrite characters)
예:R
h
Move cursor left
예:5h
j
Move cursor down
예:10j
k
Move cursor up
예:10k
l
Move cursor right
예:5l
w
Move to the start of the next word
예:3w
b
Move to the start of the previous word
예:3b
e
Move to the end of the current word
예:2e
0
Move to the beginning of the line
예:0
^
Move to the first non-blank character of the line
예:^
$
Move to the end of the line
예:$
gg
Move to the first line of the file
예:gg
G
Move to the last line of the file
예:G
:N
Jump to line number N
예::42
Ctrl+f
Scroll forward (down) one screen
예:Ctrl+f
Ctrl+b
Scroll backward (up) one screen
예:Ctrl+b
Ctrl+d
Scroll down half a screen
예:Ctrl+d
Ctrl+u
Scroll up half a screen
예:Ctrl+u
H
Move cursor to the top of the screen
예:H
M
Move cursor to the middle of the screen
예:M
L
Move cursor to the bottom of the screen
예:L
%
Jump to matching bracket, parenthesis, or brace
예:%
x
Delete the character under the cursor
예:x
dd
Delete (cut) the current line
예:dd
dw
Delete from cursor to the end of the word
예:dw
d$
Delete from cursor to the end of the line
예:d$
D
Delete from cursor to end of line (same as d$)
예:D
yy
Yank (copy) the current line
예:yy
yw
Yank (copy) from cursor to end of word
예:yw
p
Paste after the cursor
예:p
P
Paste before the cursor
예:P
u
Undo the last change
예:u
Ctrl+r
Redo the last undone change
예:Ctrl+r
cc
Change (delete and enter insert mode) the current line
예:cc
cw
Change from cursor to end of word
예:cw
c$
Change from cursor to end of line
예:c$
.
Repeat the last change
예:.
>>
Indent the current line one level to the right
예:>>
<<
Unindent the current line one level to the left
예:<<
==
Auto-indent the current line
예:==
J
Join the current line with the line below
예:J
~
Toggle case of character under cursor
예:~
r{char}
Replace the character under the cursor with {char}
예:ra
/{pattern}
Search forward for pattern
예:/foo
?{pattern}
Search backward for pattern
예:?foo
n
Repeat the last search in the same direction
예:n
N
Repeat the last search in the opposite direction
예:N
*
Search forward for the word under the cursor
예:*
#
Search backward for the word under the cursor
예:#
:s/old/new/g
Replace all occurrences of old with new on the current line
예::s/foo/bar/g
:%s/old/new/g
Replace all occurrences of old with new in the whole file
예::%s/foo/bar/g
:%s/old/new/gc
Replace all with confirmation prompts
예::%s/foo/bar/gc
:noh
Clear the search highlight
예::noh
:w
Save the current file
예::w
:w filename
Save the current buffer as a new filename
예::w newfile.txt
:q
Quit (close the window)
예::q
:wq
Save and quit
예::wq
:q!
Quit without saving (force quit)
예::q!
:x
Save and quit (only writes if changes were made)
예::x
:e filename
Open a file for editing
예::e README.md
:sp
Split the window horizontally
예::sp file.txt
:vsp
Split the window vertically
예::vsp file.txt
Ctrl+w+w
Switch focus to the next split window
예:Ctrl+w w
Ctrl+w+h/j/k/l
Move focus to the window in the given direction
예:Ctrl+w l
:close
Close the current window split
예::close
:only
Close all windows except the current one
예::only
:bn
Switch to the next buffer
예::bn
:bp
Switch to the previous buffer
예::bp
:bd
Delete (close) the current buffer
예::bd
:ls
List all open buffers
예::ls
:b N
Switch to buffer number N
예::b 2
:tabnew
Open a new tab
예::tabnew file.txt
:tabn
Switch to the next tab
예::tabn
:tabp
Switch to the previous tab
예::tabp
:tabclose
Close the current tab
예::tabclose
gt
Go to the next tab
예:gt
gT
Go to the previous tab
예:gT
q{a-z}
Start recording a macro into register {a-z}
예:qq
q (stop)
Stop recording the current macro
예:q
@{a-z}
Execute the macro stored in register {a-z}
예:@q
@@
Repeat the last executed macro
예:@@
N@{a-z}
Execute macro N times
예:5@q
:reg
Show the contents of all registers
예::reg
v then d
Select text in Visual mode then delete it
예:vwd
v then y
Select text in Visual mode then yank (copy) it
예:vwy
v then c
Select text in Visual mode then change it
예:vwc
v then >
Indent selected text to the right
예:vip>
vip
Select the current paragraph in Visual mode
예:vip
viw
Select the current word in Visual mode
예:viw
vis
Select the current sentence in Visual mode
예:vis
V then J
Select lines in Visual Line mode then join them
예:VjJ
:set number
Show line numbers
예::set number
:set nonumber
Hide line numbers
예::set nonumber
:syntax on
Enable syntax highlighting
예::syntax on
:colorscheme
Change the color scheme
예::colorscheme desert
:help {topic}
Open Vim help for a topic
예::help :w
m{a-z}
Set a mark at the current cursor position
예:ma
'{a-z}
Jump to the line of a mark
예:'a
`{a-z}
Jump to the exact position of a mark
예:`a
:set paste
Enable paste mode to avoid auto-indent issues
예::set paste
:set ignorecase
Make searches case-insensitive
예::set ignorecase
:set hlsearch
Highlight all search matches
예::set hlsearch
ga
Show the ASCII value of the character under the cursor
예:ga
zz
Center the current line on the screen
예:zz
Ctrl+g
Show the current file name and cursor position
예:Ctrl+g

이 도구에 대하여

vim 명령에 대한 포괄적인 빠른 참조 가이드입니다. 일반적으로 사용되는 명령, 구문, 예제를 범주별로 정리하여 찾아보세요. 검색 가능하고 모바일 친화적입니다. 빠른 알림이 필요할 때 즉시 액세스할 수 있도록 이 페이지를 북마크에 추가하세요.

사용 방법

  1. 분류된 참조 섹션을 찾아보세요.
  2. 검색창을 사용하여 특정 명령이나 구문을 찾으세요.
  3. 사용 예와 설명을 보려면 항목을 클릭하세요.
  4. 터미널이나 편집기에서 사용할 수 있도록 명령을 직접 복사하세요.

자주 묻는 질문

이 참조가 최신인가요?
이 참조는 여러 버전에서 안정적으로 널리 사용되는 명령과 구문을 다루고 있습니다. 최신 추가 사항이나 버전별 기능에 대해서는 공식 문서를 확인하세요.
이것을 오프라인으로 사용할 수 있나요?
페이지가 로드되면 인터넷 연결 없이도 페이지가 작동합니다. 빠른 액세스를 위해 북마크에 추가하세요. 추가 네트워크 요청 없이 모든 콘텐츠가 브라우저에서 렌더링됩니다.
이것은 포괄적입니까, 아니면 단지 기본입니까?
일상적인 작업의 90%를 처리하는 가장 일반적으로 사용되는 명령과 패턴을 다룹니다. 틈새 또는 고급 기능에 대해서는 공식 문서를 참조하세요.
추가 사항을 제안할 수 있나요?
우리는 정기적으로 참조를 업데이트합니다. 누락된 명령을 발견했거나 제안 사항이 있는 경우 연락처 페이지를 통해 알려주십시오.