vi 에디터 질문입니다.

thekeydoki의 이미지

안녕하세요.

vi 에디터에서 cindent를 적용하려고 하는데요.

적용이 안되서 문의 드립니다.

vi .exrc 하고 :set cindent 하는 걸로 알고 있습니다.
학원에서는 잘 적용되어서 잘 쓰고 있는데

집에서 공부하고자 fedora 18 을 깔고 위와 같이 똑같이 했습니다.
그런데 아무리 해도 적용이 안되네요.
:set nu같은 경우는 잘 적용됩니다.
왜 안되는지 이해가 안가는데요.
혹시 이와같은 경우 해결책이 있는지요.

버젼은 vim 7.3.712 입니다.

thekeydoki의 이미지

겨우 찾았네요.
sudo apt-get install vim
vim을 재빌드 해야 하는거네요..ㅠㅠ
그냥 처음부터 기능들이 활성화 되면 좋을텐데

. 참.. 리눅스는 힘드네요.

sunyzero의 이미지

root 계정에는 보안을 위해 최소한의 기능을 가진 minimal-vim이 작동하는 경우가 있습니다.
왠만하면 일반 계정으로 작업하신다면 문제가 없을 것 같습니다.

그리고 fedora면 yum일 것 같은데, 혹시 vim관련 부분이 설치가 안되어있다면

yum -y install vim-enhanced

라고 명령하면 vim의 확장기능까지 설치됩니다.

그리고 설정파일은 .exrc 보다 .vimrc 를 사용하는게 좋습니다.
.exrc는 호환을 위해 제공되는 구시대 유물입니다.

========================================
* The truth will set you free.

bushi의 이미지

전 fedora 12 입니다.

[bushi@rose hiber_imgs]$ sudo which vi
/bin/vi
[bushi@rose hiber_imgs]$ which vi
alias vi='vim'
	/usr/bin/vim
[bushi@rose hiber_imgs]$ 
[bushi@rose hiber_imgs]$ rpm -qf /usr/bin/vim
vim-enhanced-7.3.029-1.fc12.i686
[bushi@rose hiber_imgs]$ 
[bushi@rose hiber_imgs]$ rpm -qf /bin/vi
vim-minimal-7.3.029-1.fc12.i686
[bushi@rose hiber_imgs]$ 
 
bushi@rose hiber_imgs]$ yum provides vim
2:vim-enhanced-7.2.245-3.fc12.i686 : A version of the VIM editor which includes
                                   : recent enhancements
Repo        : fedora
Matched from:
Other       : vim
 
 
 
2:vim-enhanced-7.3.029-1.fc12.i686 : A version of the VIM editor which includes
                                   : recent enhancements
Repo        : updates
Matched from:
Other       : vim
 
 
 
2:vim-enhanced-7.3.029-1.fc12.i686 : A version of the VIM editor which includes
                                   : recent enhancements
Repo        : installed
Matched from:
Other       : Provides-match: vim
 
 
[bushi@rose hiber_imgs]$ yum provides vi
2:vim-minimal-7.2.245-3.fc12.i686 : A minimal version of the VIM editor
Repo        : fedora
Matched from:
Other       : vi
 
 
 
2:vim-minimal-7.3.029-1.fc12.i686 : A minimal version of the VIM editor
Repo        : updates
Matched from:
Other       : vi
 
 
 
2:vim-minimal-7.3.029-1.fc12.i686 : A minimal version of the VIM editor
Repo        : installed
Matched from:
Other       : Provides-match: vi
 
 
[bushi@rose hiber_imgs]$ yum info vim-minimal
Installed Packages
Name        : vim-minimal
Arch        : i686
Epoch       : 2
Version     : 7.3.029
Release     : 1.fc12
Size        : 705 k
Repo        : installed
From repo   : updates
Summary     : A minimal version of the VIM editor
URL         : <a href="http://www.vim.org/
License" rel="nofollow">http://www.vim.org/
License</a>     : Vim
Description : VIM (VIsual editor IMproved)은 업데이트되고 개선된 버전의 vi
            : 편집기입니다. Vi는 UNIX에서 사용된 첫 화면 기반 편집기이며, 여전히
            : 자주 사용되고 있습니다. VIM은 vi에 비해 다음과 같은 새로운 기능을
            : 갖습니다: 다중 화면창, 연속 실행 취소, 블록 하이라이트 기능 등.
            : vim-minimal 패키지에는 루트 파티션이 존재할 경우에만 사용할 수
            : 있는 /bin/vi에 설치된 최소 버전의 VIM이 포함되어 있습니다. 알림:
            : 온라인 도움은 단지 vim-common 패키지가 설치되었을때 유효합니다.
 
[bushi@rose hiber_imgs]$ yum info vim-enhanced
Installed Packages
Name        : vim-enhanced
Arch        : i686
Epoch       : 2
Version     : 7.3.029
Release     : 1.fc12
Size        : 1.9 M
Repo        : installed
From repo   : updates
Summary     : A version of the VIM editor which includes recent enhancements
URL         : <a href="http://www.vim.org/
License" rel="nofollow">http://www.vim.org/
License</a>     : Vim
Description : VIM (Vi IMproved)은 업데이트되고 개선된 버전의 vi 편집기입니다.
            : Vi는 UNIX에서 사용된 첫 화면 기반 편집기이며, 여전히 자주 사용되고
            : 있습니다. VIM은 vi에 비해 다음과 같은 새로운 기능을 갖습니다: 다중
            : 화면창, 연속 실행 취소, 블록 하이라이트 기능 등. vim-enhanced
            : 패키지에는 최근에 개선된 기능 (예, Python과 Perl 번역기)를
            : 포함하는 VIM 버전이 포함되어 있습니다.
            : 
            : Python과 Perl 스크립팅 언어 해석기와 같은 최신 추가 기능을
            : 포함하는 VIM 편집기 버전을 사용하시려면 vim-enhanced 패키지를
            : 설치하시기 바랍니다. vim-common 패키지도 설치해 주셔야 합니다.
 
[bushi@rose hiber_imgs]$ yum search vim
================================= Matched: vim =================================
perl-Text-VimColor.noarch : Syntax color text in HTML or XML using Vim
vim-X11.i686 : The VIM version of the vi editor for the X Window System
vim-common.i686 : The common files needed by any version of the VIM editor
vim-debuginfo.i686 : Debug information for package vim
vim-enhanced.i686 : A version of the VIM editor which includes recent
                  : enhancements
vim-filesystem.i686 : VIM filesystem layout
vim-latex.noarch : Tools to view, edit and compile LaTeX documents in Vim
vim-latex-doc.noarch : Documentation for vim-latex
vim-minimal.i686 : A minimal version of the VIM editor
vim-perl-support.noarch : Perl-IDE for VIM
vim-vimoutliner.noarch : Script for building an outline editor on top of Vim
protobuf-vim.i686 : Vim syntax highlighting for Google Protocol Buffers
                  : descriptions
vim-clustershell.noarch : VIM files for ClusterShell
vim-perl-tt2.noarch : Syntax highlighting for the Template-Toolkit
wklej-vim.noarch : A wklej.org submitter plugin for vim
vim-halibut.noarch : Syntax file for the halibut manual tool
boxes.i686 : Draw any kind of box around some given text
dvtm.i686 : Tiling window management for the console
liblinebreak.i686 : A Unicode line-breaking library
liblinebreak-debuginfo.i686 : Debug information for package liblinebreak
liblinebreak-devel.i686 : Development files for liblinebreak

댓글 달기

Filtered HTML

  • 텍스트에 BBCode 태그를 사용할 수 있습니다. URL은 자동으로 링크 됩니다.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>
  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.

BBCode

  • 텍스트에 BBCode 태그를 사용할 수 있습니다. URL은 자동으로 링크 됩니다.
  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param>
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.

Textile

  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • You can use Textile markup to format text.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>

Markdown

  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • Quick Tips:
    • Two or more spaces at a line's end = Line break
    • Double returns = Paragraph
    • *Single asterisks* or _single underscores_ = Emphasis
    • **Double** or __double__ = Strong
    • This is [a link](http://the.link.example.com "The optional title text")
    For complete details on the Markdown syntax, see the Markdown documentation and Markdown Extra documentation for tables, footnotes, and more.
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>

Plain text

  • HTML 태그를 사용할 수 없습니다.
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.
  • 줄과 단락은 자동으로 분리됩니다.
댓글 첨부 파일
이 댓글에 이미지나 파일을 업로드 합니다.
파일 크기는 8 MB보다 작아야 합니다.
허용할 파일 형식: txt pdf doc xls gif jpg jpeg mp3 png rar zip.
CAPTCHA
이것은 자동으로 스팸을 올리는 것을 막기 위해서 제공됩니다.