From owner-svn-ports-all@FreeBSD.ORG Thu Dec 4 17:28:11 2014 Return-Path: Delivered-To: svn-ports-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 5F3DF84A; Thu, 4 Dec 2014 17:28:11 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4AF36841; Thu, 4 Dec 2014 17:28:11 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.9/8.14.9) with ESMTP id sB4HSB2O036592; Thu, 4 Dec 2014 17:28:11 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by svn.freebsd.org (8.14.9/8.14.9/Submit) id sB4HSAnL036588; Thu, 4 Dec 2014 17:28:10 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201412041728.sB4HSAnL036588@svn.freebsd.org> X-Authentication-Warning: svn.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Thu, 4 Dec 2014 17:28:10 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r373973 - in head/editors: vim vim-lite vim/files X-SVN-Group: ports-head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-all@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: SVN commit messages for the ports tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 04 Dec 2014 17:28:11 -0000 Author: bapt Date: Thu Dec 4 17:28:09 2014 New Revision: 373973 URL: https://svnweb.freebsd.org/changeset/ports/373973 QAT: https://qat.redports.org/buildarchive/r373973/ Log: Move the vimrc into ETCDIR to user may have a look at it. Now install a minimalistic vimrc without all the controversial options (I hope) Define a template for port Makefiles to vim automatically creates it in case of opening a new one Added: head/editors/vim/files/vimrc (contents, props changed) Modified: head/editors/vim-lite/Makefile head/editors/vim/Makefile head/editors/vim/pkg-plist Modified: head/editors/vim-lite/Makefile ============================================================================== --- head/editors/vim-lite/Makefile Thu Dec 4 17:25:03 2014 (r373972) +++ head/editors/vim-lite/Makefile Thu Dec 4 17:28:09 2014 (r373973) @@ -1,7 +1,7 @@ # Created by: David O'Brien (obrien@NUXI.com) # $FreeBSD$ -PORTREVISION= 0 +PORTREVISION= 1 MAINTAINER= sunpoet@FreeBSD.org COMMENT= Improved version of the vi editor (lite package) Modified: head/editors/vim/Makefile ============================================================================== --- head/editors/vim/Makefile Thu Dec 4 17:25:03 2014 (r373972) +++ head/editors/vim/Makefile Thu Dec 4 17:28:09 2014 (r373973) @@ -3,7 +3,7 @@ PORTNAME= vim PORTVERSION= 7.4.${PATCHLEVEL} -PORTREVISION?= 0 +PORTREVISION?= 1 CATEGORIES?= editors MASTER_SITES= VIM:source \ ${MASTER_SITE_VIM:S|unix|patches/${PORTVERSION:R}|}:patch \ @@ -34,6 +34,7 @@ XTERM_SAVE_DESC= Restore xterm screen af ALL_TARGET= # empty MAKE_ARGS+= CC="${CC}" CONF_ARGS="--prefix=${PREFIX} ${CSCOPE_ARG}" STRIP="${STRIP_CMD}" CONF_OPT_MULTIBYTE=--enable-multibyte CONF_TERM_LIB=--with-tlib=termlib +MAKE_ARGS+= VIMRUNTIMEDIR=${PREFIX}/share/vim/${VIM_VER} VIMRCLOC=${ETCDIR} PATCH= ${LOCALBASE}/bin/gpatch PATCH_DIST_ARGS=--batch --directory ${WRKSRC} --forward --quiet --remove-empty-files ${PATCH_DIST_STRIP} REINPLACE_ARGS= -i '' @@ -153,6 +154,8 @@ post-patch: @${ECHO_MSG} "===> Applying distribution patch ${p}" @${PATCH} ${PATCH_DIST_ARGS} -i ${_DISTDIR}/${PORTVERSION:R}.${p} .endfor + @${ECHO_CMD} '#define SYS_VIMRC_FILE "'${ETCDIR}'/vimrc"' >> ${WRKSRC}/src/feature.h + @${ECHO_CMD} '#define SYS_GVIMRC_FILE "'${ETCDIR}'/gvimrc"' >> ${WRKSRC}/src/feature.h pre-configure: @${CP} ${WRKSRC}/src/config.mk.dist ${WRKSRC}/src/auto/config.mk @@ -180,8 +183,9 @@ post-install: .endfor .endif .if ${PORT_OPTIONS:MDEFAULT_VIMRC} - ${INSTALL_DATA} ${WRKSRC}/runtime/gvimrc_example.vim ${STAGEDIR}${DATADIR}/gvimrc.sample - ${INSTALL_DATA} ${WRKSRC}/runtime/vimrc_example.vim ${STAGEDIR}${DATADIR}/vimrc.sample + ${MKDIR} ${STAGEDIR}${ETCDIR} + ${INSTALL_DATA} ${FILESDIR}/vimrc ${STAGEDIR}${ETCDIR}/gvimrc.sample + ${INSTALL_DATA} ${FILESDIR}/vimrc ${STAGEDIR}${ETCDIR}/vimrc.sample .endif .if !${PORT_OPTIONS:MNLS} ${MKDIR} ${STAGEDIR}${DATADIR}/${VIM_VER}/keymap/ Added: head/editors/vim/files/vimrc ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/editors/vim/files/vimrc Thu Dec 4 17:28:09 2014 (r373973) @@ -0,0 +1,23 @@ +if v:lang =~ "utf8$" || v:lang =~ "UTF-8$" + set fileencodings=ucs-bom,utf-8,latin1 +endif + +set nocompatible +set bs=indent,eol,start +set history=50 +set ruler + +if &t_Co > 2 || has("gui_running") + syntax on + set hlsearch +endif + +if has("autocmd") + augroup freebsd + autocmd! + if $PORTSDIR != "" + autocmd BufNewFile $PORTSDIR/*/*/Makefile 0r $PORTSDIR/Templates/Makefile + else + autocmd BufNewFile /usr/ports/*/*/Makefile 0r /usr/ports/Templates/Makefile + endif +endif Modified: head/editors/vim/pkg-plist ============================================================================== --- head/editors/vim/pkg-plist Thu Dec 4 17:25:03 2014 (r373972) +++ head/editors/vim/pkg-plist Thu Dec 4 17:28:09 2014 (r373973) @@ -1,3 +1,5 @@ +%%DEFAULT_VIMRC%%@sample %%ETCDIR%%/gvimrc.sample +%%DEFAULT_VIMRC%%@sample %%ETCDIR%%/vimrc.sample %%GUI%%bin/eview bin/evim @comment bin/ex @@ -184,5 +186,3 @@ man/man1/xxd.1.gz %%NON_LITE%%%%NLS%%man/ru.UTF-8/man1/vimdiff.1.gz %%NON_LITE%%%%NLS%%man/ru.UTF-8/man1/vimtutor.1.gz %%NON_LITE%%%%NLS%%man/ru.UTF-8/man1/xxd.1.gz -%%DEFAULT_VIMRC%%@sample share/vim/gvimrc.sample -%%DEFAULT_VIMRC%%@sample share/vim/vimrc.sample