U E D R , A S I H C RSS

Vi Improved/설명서

~cpp 
1.VI(Visual interface Editor) 

구 	 	 	  (binary)
	 	  source data   (ASCII)
▶Editor(unix system)	Line editor	  (ex ed)
	Screen editor	  (vi)
▶Vi 	vi ex The University of California, Berkeley California computer Science Division, Department of Electrical Engineering and Computer Science
▶Vi 	()	    , ,     ; <ESC>
	 	  (a A I ...)  : <ESC>
		(: / ? !)      CR( )    <DEL>  ;  
▶Vi 	 	[from][.][to][][ ] or [n][][ ]
	  	/  (z G | )  (^D ^U)  과 ()
	  	 (.) (d s c ..)   
▶.exrc 	 	vi      vi     vi set      .exrc   set값 default  
	 	set wm=3 set sm ##  .  bbm bbmaster@flower.chungnam.ac.kr  ab bbm bbmaster@flower.chungnam.ac.kr ##    map V :w^M:!spell -x %^M:e!^M^M
  	 	vi         ) d , dw  , db   .
		 Ctrl    ) ^u Ctrl   u   
		      . )     
		      
		     


▶File 	   
 (↓: CR)	
	 	
		ZZ (=:wq)	     
		:w ↓	  기
		:w! ↓	   기
		:w <file>↓	 name 기
		:w! <file>↓	 name 기
		:q↓	vi고 Unix 
		:q!↓	  vi   
	 	
		:e <file>↓	  
		:e!↓	 
		:e+ <file>↓	  
		:e +n↓	n   
		:e #↓	  file 
		:e! #↓	   file 
	 	
		:r <file> ↓	<file>   read 
		:r !<>↓	<>  결과 read 
		:nr <file>↓	n  <file> read
	기 	
		:sh↓	  vi (^d, exit )
		:!cmd↓	 cmd 
		:n args↓	   
		^G	  
		:ta tag↓	 tag 
		:f<ESC>	?
	  	
		$vi A B C D	4개 (A B C D)     
		:n	        
	 구	
		$vi -r 	 ( ),       	   
	
	/	
		n	  n  
		+ (n+)	  ( n)  
		- (n-)	  ( n)  
		G	     
		1G	     
		nG	 n    
		H	  
		L	  
		M	  
		CR	+  j	    k	  
	1	
		^	공   
		O	 
		$	 
		h  
		l  
		^H	←(  ) 
		nl	  n 
		space	→( ) 
		fc (nfc)	   c 
		Fc (nFc)	   c 
		tc (ntc)	   c  
		Tc (nTc)	   c  
		; (n;)	      c 
		, (n,)	      c 
		
		w (nw)	     () 
		W (nW)	  () 
		e (ne)	     () 
		E (nE)	  () 
		b (nb)	()     () 
		B nB	  () 
	//	
		{ or n{	      
		} or n}	     
		(	    
		)	    
		]] or n]]	    
		[[ or n[[	     
		
		^F n^F	  기
		^B n^B	  기
		^D n^D	  
		^U n^U	  
		^Y n^Y	   
		^E n^E	   
		z	  top ,  
		z.	   ,  
		z-	  bottom ,  
		^L	  (refresh)
		^R	^L →key   고 refesh

구 	   
 (insert)	
	a	    
	i	    
	A	    
	I	    
	o	   
	O	   

 	
	^H	  ( )
	^W	  
	erase	  ^H 
	kill	   .    거
	\	     ESC
	ESC	   
	DEL	   
	^D	  back tab. autointent   
	^^D	(^)  control-d(^D) . 
		  back tab. autointent    
	O^D	  back tab autointent   
	^V	    ESC
	
	J	     
기(delete)	
		
		x nx	    
		X nX	    
		D	        
		d0	       
		
		dd ndd	 ( n) 
		dG	       
		d1G	        
		dnG	 , n     
		d-	    
		d+	  
		nd-	  n   
		nd+	  n   
		ddp	  
	//구	
		d) dn)	      
		d( dn(	       
		d} dn}	   paragraph   
		d{ dn{	 paragraph      
		d] dn]	   section   
		d[ dn[	 section     
		
		dfc dnfc	   (n) 'c'  
		dFc dnFc	   (n) 'c'  
		dtc dntc	    (n) 'c'  
		dTc dnTc	     (n) 'c'  
		d/pat	     (pat)
		d?pat	     (pat)까
	text구	
		p	 (change, delete, yank)   
		P	 (change, delete, yank)   
	구	
		$vi -r <>	<>  기기  * ,  *

구 	  		
		cw cnw	 (n )  경
		cW cnW	 (n )  경
		cb cnb	 (n)    경
		cB cnB	 (n)    //구	
		c) cn)	     경
		c( cn(	      경
		c} cn}	   paragraph  경
		c{ cn{	 paragraph     경
		c]] cn]]	   section  경
		c[[ cn[[	 section     	
		cfc cnfc	   (n) 'c' 경
		cFc cnFc	   (n) 'c' 경
		ctc cntc	    (n) 'c' 경
		cTc cnTc	    (n) 'c'  	
	/		  
	10,20/	10 20  
	1,$/	   
	//+n	    n  
	?		   
	??+n	    n  
	n		    (/)
	N		    (?)
(^)기	
	:/^M(^V+^M)	 (^)     ^V        
 (replacement)	:
	[]s/old/new/[cgi]  ( . , * [ ^ $ \ / &) 각각 (\. \* \[ \^ \$ \ \/ \&)
	[]	
		[]  
		[$]  
		[. ]   
		[%] 
	[cgi]	
		[c]     
		[g]       
		[i]    
	:s/old/new/g	
		   
	:10,$s/old/new/g	
		10   
	:g/A/s//B/g	
		 A (g/A)
		A B  (s//B), s // text    
		    (/g) 
	:g/ABC/s/B/Z/g	
		 ABC (s/B/Z)
		ABC B  Z  (/g)
		    (/g) 

구 	   
Mark()	 	mc	   'c'  ('c'  1 )
	 	'c	'c'   
		`	'c'     
		"	,     
		``	,   
	 / 	:10,20w 	10 20  
		:10,20w >> 	10 20  
	 	:10,20r 	10 20    
	기(yank)	"a5dd	   5고, a  
	 	yw	  
		3yw	3 
		y$	  
		y)	  
		yy nyy	 (n개)  (Y)
		"a5Y	   5 a  
	기(put)	p	      
		P	      
		"ap	a       
		"np	n    , yank    
( )	 	:map<><기>	<>  10
			<기>  100
			*) vi bug      
	 	:unmap <>	 
	 	:map #n <기>	 <> #n - n 0 9까  - , 그     . 
		:map #2 :w^M	  F2  :w^M 
	 	:map V	:w^M:!ispell -x $^M:e!^M^M ( )
		:map #2	:w^M: !cc %^M:e!^M^M (vi F2 )
 	.	  
	J	
	~	  
	^1	 
 	 	commond 
:	ex()	^f	    	:r <file>	<file>   read
)	 sentence	G	. . . (dft )	:r !<>	<>결과 read
(	 sentence	^g	  	:nr <file>	n<file> read
}	paragraph	h	  	:! 	  
{	paragraph	H	   	:sh	 감
]]	 section	^h	 backspace	:x	기
[[	 section	i	   	:wq	기
0()	 line   	I	  	:11,22w <file>	 11과 12  
$	 line  	^i	tab ()	:w >> <file>	 <file> 
^	 line   	j	 	:w!	  기
+	   	k	 	:q	기(  )
-	   	l	 	:q!	경과  
spacebar		L	   	:e <file>	vi  고<file> 
return	 	^l	refresh	:e! 	 
/	  	m	  	:n	 
?	  	M	  	:n <files>	   <file>
%	   (,{,[,-),},} 	^m	 (CR)		
,	f,F,t,T  	n	   	:e#	  <file>
;	f,F,t,T  	N	   	:args	  
.	  	^n	 ( )	:rew	  
`	mark 	o	   	:map m n	
'	    	O	  	:map! m n	 ( )
``	  곳 or  	p	  	:unmap m	 
''	``  	P	  	:unmap! m	 ()
~	 	^p	 ( )	:ab <1> <2>	 
"	 	Q	고 ex 	:unab <1>	 
!!	   	r	 	:set <option>	set 
!	send next to commend, replace output(eg !)	R	  ( ESC  )	:set number	 기
>>	 shiftwith paragraph 	^r	refresh( )	!}	   unix     결과  과 교 
<<	 shiftwith paragraph 	s	교		
>%	 (,{,[  	S	그    		
<%	 (,{,[  	t	    		
a	   	T	 "		
A	  	^t	 shiftwith 		
b	   	u	  		
B	   	U	   		
^b	   	^u	  		
c	   경	^V	    		
C	   경	w	   		
^c	 ( x)	W	  		
d	.  text	^w	   () 		
D	  	x	  		
^d	   	X	  		
e	   	y	. . .  yank		
E	   	Y	 yank		
^e	   	^y	  		
f	. . .  	z	 top(. mid -bot)		
F	. . .   	ZZ	감(=wq)		
set  
Option	Default	
:set <option> <param>	
:set <nooption> <param>	set  <option> no 
:set all	  vi        
autoindent(ai)	noai	 기 기 
autoprint(ap)	ap	각     
autowrite(aw)	noaw	     (:n, :!) 
beautify(bf)	nobf	       tab, newline, formfeed  
directory(dir=)	/tmp	   
edcmpatible	noedcmpatible	ed
errorbells(eb)	errorbells	  
exrc(ex)	noexrc	home   .exrc 
hardtaps=(ht=)	8	    
ignore case(ic)	noic	  
lisp	nolisp	indentation lisp 
list	nolist	   ^I,   $ 
magic	magic	[*.      
mesg	masg	   
number(nu)	nonumber	   
open	noopen	Vi ex 
optimize(opt)	optimize	
paragraphs=(para=)	IPLPPQPPLIbp	   
prompt	prompt	ex prompt 
readonly(ro)	noro	!   
reraw	noredraw	
remap	remap	map   
report=	5	   공
scroll	1/2	   
sections=	SHNHH	section   
shell=(sh=)		  
shiftwith=(sw=)		       
showmatch(sm)		{,(   },)  1   
showmode	noshowmode	    "input mode"
slowopen(slow)		tab   공간 
tabstop(ts=)		  tab간격  
taglength(tl=)		tab    
tags=	tag	/usr/lib/tags    pass
term=		  
timeout(to)	timeout	간   
tty type=	Set	1   "time out" 
warn	warn	  
window=(w=)		      경고  
wrapmargin=(wm=)	0	    
wrapscan(ws)	ws	  
writeany(wa)	nowa	     
Valid XHTML 1.0! Valid CSS! powered by MoniWiki
last modified 2021-02-07 05:28:22
Processing time 0.0369 sec