diff --git a/.cvsignore b/.cvsignore index 153e17c..cf3d3d6 100644 --- a/.cvsignore +++ b/.cvsignore @@ -1,2 +1,3 @@ -vim-5.7-rt.tar.gz -vim-5.7-src.tar.gz +vim-6.0z-lang.tar.bz2 +vim-6.0z-rt.tar.bz2 +vim-6.0z-src.tar.bz2 diff --git a/gvim.desktop b/gvim.desktop new file mode 100644 index 0000000..7653699 --- /dev/null +++ b/gvim.desktop @@ -0,0 +1,63 @@ +[Desktop Entry] +Name=Vi IMproved +Name[bg]=Vi Ðåäàêòîð +Name[ca]=Vi Millorat +Name[da]=Vi forbedret +Name[eo]=VIM +Name[et]=Täiustatud Vi (vim) +Name[fr]=Vi étendu (VIM) +Name[he]=רפושמ Vi +Name[hu]=Vi +Name[is]=Vi IMproved ritillinn +Name[it]=Vi iMproved +Name[no]=Vi IMproved (forbedret VI) +Name[pl]=Poprawiony VI (vim) +Name[ro]=VIM +Name[ru]=Улучшенный VI +Name[sk]=Vi IMpreved +Name[sl]=Izboljšani vi (vim) +Name[sv]=Förbättrad Vi +Name[zh_CN.GB2312]=改进的 Vi +Comment=Powerful vi editor +Comment[bg]=Ðåäàêòîð ñ ìíîãî âúçìîæíîñòè +Comment[ca]=Editor vi potent +Comment[cs]=Mocný textový editor vi +Comment[da]=En kraftig vi tekstbehandler +Comment[de]=Ein leistungsfähiger vi-Editor +Comment[el]=Πανίσχυρος διορθωτής vi +Comment[eo]=VIM similas al redaktilo "vi", sed havas aldonajn ecojn +Comment[es]=Una versión mejorada del editor vi +Comment[et]=Võimas tekstiredaktor vi +Comment[fi]=Tehokas vi-tekstieditori +Comment[fr]=Éditeur vi puissant +Comment[gl]=Potente editor vi +Comment[he]=Vi המצועה בר ךרועה +Comment[hr]=Napredni vi uređivač +Comment[hu]=Vi szövegszerkesztő +Comment[is]=Öflug útgáfa vi ritilsins +Comment[it]=Un editor vi potenziato +Comment[ja]=強力なViエディタ +Comment[lt]=Galingas vi redaktorius +Comment[mk]=Моќен VI уредувач +Comment[nl]=Krachtige vi-editor +Comment[no]=En kraftig vi-redigerer +Comment[no_NY]=Kraftig vi-tekstredigeringsprogram +Comment[pl]=Edytor vi +Comment[pt]=Um poderoso editor de texto +Comment[ro]=Un editor de texte VI, puternic +Comment[ru]=Мощный текстовый редактор vi +Comment[sk]=Silný textový procesor vi +Comment[sl]=Zmogljivi urejevalnik vi +Comment[sr]=Moćni vi editor +Comment[sv]=En kraftfull texteditor +Comment[ta]=ºì¾¢Å¡öó¾ vi ¦¾¡ÌôÀ¡Ç÷ +Comment[tr]=Güçlü vi düzenleyicisi +Comment[uk]=Потужний редактор vi +Comment[zh_CN.GB2312]=功能强大的 vi 编辑器 +MimeType=text/english;text/plain;text/x-makefile;text/x-c++hdr;text/x-c++src;text/x-chdr;text/x-csrc;text/x-java;text/x-moc;text/x-pascal;text/x-tcl;text/x-tex;application/x-shellscript;text/x-c;text/x-c++; +Exec=gvim -f %f +Icon=gvim +Type=Application +Terminal=0 +XClassHintResName=VIM +MapNotify=false diff --git a/sources b/sources index 0f1f716..f26abb4 100644 --- a/sources +++ b/sources @@ -1,2 +1,3 @@ -b7d9cbc64479e26f52e2bc58d312bd84 vim-5.7-rt.tar.gz -0b2bca69c7018a8777d8d5390e23d06e vim-5.7-src.tar.gz +78597560a02c2050def298bca8ffaaa4 vim-6.0z-lang.tar.bz2 +c101f51a4658e71709a4bef513946aa6 vim-6.0z-rt.tar.bz2 +460dc963fdf2d6c52f2d16f48316e991 vim-6.0z-src.tar.bz2 diff --git a/vim.spec b/vim.spec index 2b36fa8..b785751 100644 --- a/vim.spec +++ b/vim.spec @@ -1,36 +1,26 @@ Summary: The VIM editor. Name: vim -Version: 5.7 -%define vimversion vim57 -Release: 8tc1 -Packager: Red Hat, Inc. -Vendor: Red Hat, Inc. -Copyright: Charityware +Version: 6.0 +%define alpha z +%define vimversion vim60%{alpha} +Release: 0.27 +Copyright: freeware Group: Applications/Editors -Source0: ftp://ftp.home.vim.org/pub/vim/unix/vim-%{version}-src.tar.gz -Source1: ftp://ftp.home.vim.org/pub/vim/unix/vim-%{version}-rt.tar.gz -# By CLE { -Source3: vimrc -Source4: gvimrc -# } +Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{version}%{alpha}-src.tar.bz2 +Source1: ftp://ftp.vim.org/pub/vim/unix/vim-%{version}%{alpha}-rt.tar.bz2 +Source2: ftp://ftp.vim.org/pub/vim/unreleased/extra/vim-%{version}%{alpha}-lang.tar.bz2 +Source3: gvim.desktop +Source4: vimrc Patch0: vim-4.2-speed_t.patch Patch1: vim-5.1-vimnotvi.patch Patch2: vim-5.6a-paths.patch -Patch3: vim-5.6-fixkeys.patch -Patch4: vim-5.6-specsyntax.patch -Patch5: vim-5.6-destdir.patch -Patch6: vim-5.7-redhat.patch -Patch7: vim-5.7-docpath.patch -Patch8: vim-5.7-crv.patch -Patch101: 5.7.001 -Patch102: 5.7.002 -Patch103: 5.7.003 -Patch104: 5.7.004 -Patch105: 5.7.005 -Patch106: 5.7.006 -Patch107: 5.7.007 -Patch108: 5.7.008 -Buildroot: /var/tmp/vim-root +Patch3: vim-6.0-fixkeys.patch +Patch4: vim-6.0-specsyntax.patch +Patch5: vim-6.0r-crv.patch +Patch6: vim-6.0z-menui18n.patch +Patch7: vim-6.0t-phphighlight.patch +Patch8: vim-6.0v-lilo.patch +Buildroot: %{_tmppath}/%{name}-%{version}-root Buildrequires: python-devel perl gtk+-devel %description @@ -107,7 +97,7 @@ with graphics and mouse capabilities. You'll also need to install the vim-common package. %prep -%setup -q -b 1 +%setup -q -b 1 -n %{vimversion} %patch0 -p1 -b .4.2 %patch1 -p1 -b .vim # fix rogue dependencies from sample code @@ -116,20 +106,10 @@ chmod -x runtime/tools/mve.awk find . -name \*.paths | xargs rm -f %patch3 -p1 -b .fixkeys %patch4 -p1 -b .highlite -%patch5 -p1 -b .destdir -%patch6 -p1 -b .redhat -%patch7 -p1 -b .docs -%patch8 -p1 -b .crv - -%patch101 -p0 -b .p1 -%patch102 -p0 -b .p2 -%patch103 -p0 -b .p3 -%patch104 -p0 -b .p4 -%patch105 -p0 -b .p5 -%patch106 -p0 -b .p6 -%patch107 -p0 -b .p7 -%patch108 -p0 -b .p8 - +%patch5 -p1 -b .crv +%patch6 -p1 -b .menui18n +%patch7 -p1 -b .php +%patch8 -p1 -b .lilo perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %build @@ -137,33 +117,24 @@ cd src perl -pi -e "s,\\\$VIMRUNTIME,/usr/share/vim/%{vimversion},g" os_unix.h perl -pi -e "s,\\\$VIM,/usr/share/vim/%{vimversion}/macros,g" os_unix.h -%configure --enable-max-features=yes --enable-pythoninterp --enable-perlinterp --disable-tclinterp --with-x=yes --enable-gui=gtk --exec-prefix=/usr/X11R6 --enable-xim --enable-multibyte --enable-fontset -make if_perl.c -perl -pi -e "s,#define.*PL_na.*,,g" if_perl.c -perl -pi -e "s,#define.*PL_defgv.*,,g" if_perl.c -perl -pi -e "s,#define.*PL_errgv.*,,g" if_perl.c +export CFLAGS="$RPM_OPT_FLAGS -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64" +export CXXFLAGS="$RPM_OPT_FLAGS -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64" + +%configure --with-features=huge --enable-pythoninterp --enable-perlinterp --disable-tclinterp --with-x=yes --enable-gui=gnome --exec-prefix=/usr/X11R6 --enable-xim --enable-multibyte --enable-fontset make cp vim gvim make clean -%configure --prefix=/usr --enable-max-features=yes --enable-pythoninterp \ +%configure --prefix=/usr --with-features=huge --enable-pythoninterp \ --enable-perlinterp --disable-tclinterp --with-x=no --enable-gui=no \ - --exec-prefix=/usr -make if_perl.c -perl -pi -e "s,#define.*PL_na.*,,g" if_perl.c -perl -pi -e "s,#define.*PL_defgv.*,,g" if_perl.c -perl -pi -e "s,#define.*PL_errgv.*,,g" if_perl.c + --exec-prefix=/usr --enable-multibyte --enable-fontset make cp vim enhanced-vim make clean -%configure --prefix='${DEST}'/usr --enable-min-features=yes --with-x=no \ +%configure --prefix='${DEST}'/usr --with-features=tiny --with-x=no \ --disable-pythoninterp --disable-perlinterp --disable-tclinterp \ --with-tlib=termcap --enable-gui=no --disable-gpm --exec-prefix=/ -make if_perl.c -perl -pi -e "s,#define.*PL_na.*,,g" if_perl.c -perl -pi -e "s,#define.*PL_defgv.*,,g" if_perl.c -perl -pi -e "s,#define.*PL_errgv.*,,g" if_perl.c make @@ -181,13 +152,14 @@ install -s -m755 enhanced-vim $RPM_BUILD_ROOT/usr/bin/vim ( cd $RPM_BUILD_ROOT mv ./bin/vim ./bin/vi - mv ./bin/vimtutor ./usr/bin rm -f ./bin/rvim ln -sf vi ./bin/view ln -sf vi ./bin/ex ln -sf vi ./bin/rvi ln -sf vi ./bin/rview ln -sf vim ./usr/bin/ex + ln -sf gvim ./usr/X11R6/bin/gview + ln -sf gvim ./usr/X11R6/bin/gex perl -pi -e "s,$RPM_BUILD_ROOT,," .%{_mandir}/man1/vim.1 .%{_mandir}/man1/vimtutor.1 rm -f .%{_mandir}/man1/rvim.1 ln -sf vim.1.gz .%{_mandir}/man1/vi.1.gz @@ -195,19 +167,15 @@ install -s -m755 enhanced-vim $RPM_BUILD_ROOT/usr/bin/vim ln -sf vim.1.gz .%{_mandir}/man1/gvim.1.gz ln -sf gvim ./usr/X11R6/bin/vimx mkdir -p ./etc/X11/applnk/Utilities - cat > ./etc/X11/applnk/Utilities/gvim.desktop < -- Candyz alreay patch this on CLE 0.9p1 -- rebuild on RH7 +* Fri Mar 30 2001 Bernhard Rosenkraenzer +- Fix large file handling (#34061) + +* Mon Feb 26 2001 Trond Eivind Glomsr�d +- use %%{_tmppath} + +* Thu Feb 15 2001 Yukihiro Nakai +- vimrc update for 6.0v + +* Mon Feb 12 2001 Bernhard Rosenkraenzer +- Fix "lba32" keyword in lilo.conf syntax highlighting +- Fix build with current glibc + +* Fri Feb 2 2001 Bernhard Rosenkraenzer +- Fix crontab -e in vim-minimal (#25376) + +* Tue Jan 30 2001 Bernhard Rosenkraenzer +- Fix segfault on q, up, up, q (Bug #25261) + +* Mon Jan 22 2001 Bernhard Rosenkraenzer +- Set minlines=500 as default in PHP syntax highlighting (RFE #24374) +- Don't symlink gvimrc to vimrc (Bug #22518) +- Add symlinks gview -> gvim and gex -> gvim in -X11 (RFE #24394) +- 6.0t + +* Mon Jan 15 2001 Bernhard Rosenkraenzer +- More fixes to rpm specfile syntax highlighting: + - recognize %%ifnarch + - recognize "j" as a tar option + - recognize %{_libdir} + +* Sun Jan 14 2001 Bernhard Rosenkraenzer +- 6.0s + +* Wed Jan 3 2001 Bernhard Rosenkraenzer +- 6.0r +- Restore crv patch (this should fix #23135 for whoever is seeing it; + I'm not). + +* Tue Dec 19 2000 Yukihiro Nakai +- Symbolic link to menu_ja_jp.ujis.vim to menu_ja_jp.eucjp.vim + +* Mon Dec 18 2000 Yukihiro Nakai +- Delete i18n patch (already implmented by author) +- Add menu i18n patch +- Update vimrc to support CJK +- Add menu translations. + +* Sun Dec 17 2000 Bernhard Rosenkraenzer +- 6.0q + +* Sun Dec 17 2000 Yukihiro Nakai +- Add --enable-fontset to configure options. +- Add i18nrc patch and resources. + +* Tue Dec 12 2000 Bernhard Rosenkraenzer +- 6.0p, new ncurses + +* Mon Dec 11 2000 Karsten Hopp +- rebuilt to fix permissions of /usr/share/doc/ and + /usr/share/vim + +* Mon Nov 13 2000 Bernhard Rosenkraenzer +- 6.0m + +* Thu Nov 9 2000 Bernhard Rosenkraenzer +- 6.0l + +* Mon Oct 30 2000 Bernhard Rosenkraenzer +- 6.0k + +* Tue Oct 17 2000 Bernhard Rosenkraenzer +- 6.0i +- add new desktop file w/ translations -* Wed Oct 11 2000 Chung-Yen Chang -- configure with --enable-xim --enable-multibyte --enable-fontset -- add default vimrc and gvimrc for Chinese +* Thu Aug 31 2000 Bernhard Rosenkraenzer +- 6.0h +* Wed Aug 30 2000 Bernhard Rosenkraenzer +- 6.0g -* Sun Aug 6 2000 Tim Waugh -- xterm doesn't have request version string (#14570) +* Mon Aug 14 2000 Bernhard Rosenkraenzer +- 6.0f -* Sat Aug 5 2000 Bernhard Rosenkraenzer -- Patchlevel 8 +* Wed Aug 9 2000 Bernhard Rosenkraenzer +- 6.0e -* Fri Aug 4 2000 Bernhard Rosenkraenzer -- Fix paths in vim.1 manpage (Bug #15387) +* Sun Jul 23 2000 Bernhard Rosenkraenzer +- 6.0c +- get rid of the DESTDIR patch, no longer needed -* Wed Jul 19 2000 Bernhard Rosenkraenzer -- Fix up vimtutor (Bug #11455) +* Sun Jul 16 2000 Bernhard Rosenkraenzer +- 6.0b -* Thu Jul 13 2000 Prospector -- automatic rebuild +* Mon Jul 10 2000 Bernhard Rosenkraenzer +- 6.0a * Sun Jun 25 2000 Bernhard Rosenkraenzer - 5.7 release diff --git a/vimrc b/vimrc index f06ab8e..30fee46 100644 --- a/vimrc +++ b/vimrc @@ -1,37 +1,104 @@ -"" (for Chinese) -"" Set file encoding format as 'taiwan' for Chinese -"" Only fe is only set when in rxvt which defines COLORTERM -"" environment variable -if exists("$COLORTERM") - set fe=taiwan +if v:lang =~ "^ko" + set fileencodings=euc-kr + set guifontset=-*-*-medium-r-normal--16-*-*-*-*-*-*-* +elseif v:lang =~ "^ja_JP" + set fileencodings=euc-jp + set guifontset=-misc-fixed-medium-r-normal--14-*-*-*-*-*-*-* +elseif v:lang =~ "^zh_TW" + set fileencodings=big5 + set guifontset=-sony-fixed-medium-r-normal--16-150-75-75-c-80-iso8859-1,-taipei-fixed-medium-r-normal--16-150-75-75-c-160-big5-0 +elseif v:lang =~ "^zh_CN" + set fileencodings=gb2312 + set guifontset=*-r-* +endif +if v:lang =~ "utf8$" || v:lang =~ "UTF-8$" + set fileencodings=utf-8 +endif + +set nocompatible " Use Vim defaults (much better!) +set bs=2 " allow backspacing over everything in insert mode +"set ai " always set autoindenting on +"set backup " keep a backup file +set viminfo='20,\"50 " read/write a .viminfo file, don't store more + " than 50 lines of registers +set history=50 " keep 50 lines of command line history +set ruler " show the cursor position all the time + +" Only do this part when compiled with support for autocommands +if has("autocmd") + " In text files, always limit the width of text to 78 characters + autocmd BufRead *.txt set tw=78 + " When editing a file, always jump to the last cursor position + autocmd BufReadPost * if line("'\"") | exe "'\"" | endif endif -"" (for Chinese) -"" Set ruler on, you must set this to ensure -"" the Chinese functionality of gvim -set ru +" Don't use Ex mode, use Q for formatting +map Q gq -"" Set visual bell and disable screen flash -:set vb t_vb= +" Switch syntax highlighting on, when the terminal has colors +" Also switch on highlighting the last used search pattern. +if &t_Co > 2 || has("gui_running") + syntax on + set hlsearch +endif + +if has("autocmd") + augroup cprog + " Remove all cprog autocommands + au! -"" Toggle on/off highlightsearch -map :set hls!set hls? + " When starting to edit a file: + " For C and C++ files set formatting of comments and set C-indenting on. + " For other files switch it off. + " Don't change the order, it's important that the line with * comes first. + autocmd FileType * set formatoptions=tcql nocindent comments& + autocmd FileType c,cpp set formatoptions=croql cindent comments=sr:/*,mb:*,el:*/,:// + augroup END -"" Toggle on/off paste mode -map :set paste!set paste? + augroup gzip + " Remove all gzip autocommands + au! -"" You can toggle the syntax on/off with this command -if has("syntax_items") | syntax off | else | syntax on | endif -map :if has("syntax_items") syntax off else syntax on endif + " Enable editing of gzipped files + " read: set binary mode before reading the file + " uncompress text in buffer after reading + " write: compress file after writing + " append: uncompress file, append, compress file + autocmd BufReadPre,FileReadPre *.gz set bin + autocmd BufReadPost,FileReadPost *.gz let ch_save = &ch|set ch=2 + autocmd BufReadPost,FileReadPost *.gz '[,']!gunzip + autocmd BufReadPost,FileReadPost *.gz set nobin + autocmd BufReadPost,FileReadPost *.gz let &ch = ch_save|unlet ch_save + autocmd BufReadPost,FileReadPost *.gz execute ":doautocmd BufReadPost " . expand("%:r") -syntax on + autocmd BufWritePost,FileWritePost *.gz !mv :r + autocmd BufWritePost,FileWritePost *.gz !gzip :r -"" Set non-compatible with vi -set nocompatible + autocmd FileAppendPre *.gz !gunzip + autocmd FileAppendPre *.gz !mv :r + autocmd FileAppendPost *.gz !mv :r + autocmd FileAppendPost *.gz !gzip :r + augroup END +endif +if &term=="xterm" + set t_Co=8 + set t_Sb=^[4%dm + set t_Sf=^[3%dm +endif -"" Set backup extension -set backup -set backupext=.bak +" some extra commands for HTML editing +nmap ,mh wbgueyei<ea>pa>bba +nmap ,h1 _i

A

+nmap ,h2 _i

A

+nmap ,h3 _i

A

+nmap ,h4 _i

A

+nmap ,h5 _i
A
+nmap ,h6 _i
A
+nmap ,hb wbieabb +nmap ,he wbieabb +nmap ,hi wbieabb +nmap ,hu wbieabb +nmap ,hs wbieabb +nmap ,ht wbieabb +nmap ,hx wbFf -"" Map for parenthesis matching -map \ %