티스토리 뷰

learning

Change the current directory on Vim

눈침침 2011. 6. 20. 16:15

빔(VIM)에서 현재 폴더의 위치를 변경하고 싶을 때!

Vim 에서 현재 디렉토리를 변경할 때는 :cd 라고 입력한 뒤, 가고 싶은 폴더 경로를 입력하면 된다. 이렇게 쉬운 명령어였을 줄이야.
만약 {홈디렉토리}/workspace로 이동하고 싶을 땐, 아래와 같이 입력하면 된다.

:cd ~/workspace

Change the current directory to {path}.
If {path} is relative, it is searched for in the directories listed in 'cdpath'.
Does not change the meaning of an already opened file, because its full path name is remembered. Files from the |arglist| may change though! On MS-DOS this also changes the active drive.
To change to the directory of the current file:

:cd %:h
VIM Doc
공지사항
최근에 올라온 글
최근에 달린 댓글
Total
Today
Yesterday
링크
«   2024/05   »
1 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30 31
글 보관함