Compare commits
4 commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
306de96327 | ||
|
|
ba0a275ec6 | ||
| c5d9b63872 | |||
| e838aa796f |
5 changed files with 133 additions and 21 deletions
1
.gitignore
vendored
Normal file
1
.gitignore
vendored
Normal file
|
|
@ -0,0 +1 @@
|
|||
perl-support.zip
|
||||
21
Makefile
21
Makefile
|
|
@ -1,21 +0,0 @@
|
|||
# Makefile for source rpm: vim-perl-support
|
||||
# $Id$
|
||||
NAME := vim-perl-support
|
||||
SPECFILE = $(firstword $(wildcard *.spec))
|
||||
|
||||
define find-makefile-common
|
||||
for d in common ../common ../../common ; do if [ -f $$d/Makefile.common ] ; then if [ -f $$d/CVS/Root -a -w $$/Makefile.common ] ; then cd $$d ; cvs -Q update ; fi ; echo "$$d/Makefile.common" ; break ; fi ; done
|
||||
endef
|
||||
|
||||
MAKEFILE_COMMON := $(shell $(find-makefile-common))
|
||||
|
||||
ifeq ($(MAKEFILE_COMMON),)
|
||||
# attept a checkout
|
||||
define checkout-makefile-common
|
||||
test -f CVS/Root && { cvs -Q -d $$(cat CVS/Root) checkout common && echo "common/Makefile.common" ; } || { echo "ERROR: I can't figure out how to checkout the 'common' module." ; exit -1 ; } >&2
|
||||
endef
|
||||
|
||||
MAKEFILE_COMMON := $(shell $(checkout-makefile-common))
|
||||
endif
|
||||
|
||||
include $(MAKEFILE_COMMON)
|
||||
1
sources
1
sources
|
|
@ -0,0 +1 @@
|
|||
aa23b91d3487dd593b64114189b29a28 perl-support.zip
|
||||
131
vim-perl-support.spec
Normal file
131
vim-perl-support.spec
Normal file
|
|
@ -0,0 +1,131 @@
|
|||
Name: vim-perl-support
|
||||
Version: 3.9.1
|
||||
Release: 1%{?dist}
|
||||
Summary: Perl-IDE for VIM
|
||||
|
||||
Group: Applications/Editors
|
||||
# according to plugin/perl-support.vim
|
||||
License: GPLv2
|
||||
URL: http://www.vim.org/scripts/script.php?script_id=556
|
||||
# curl -o perl-support.zip 'http://www.vim.org/scripts/download_script.php?src_id=9578'
|
||||
Source0: perl-support.zip
|
||||
BuildRoot: %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)
|
||||
|
||||
BuildArch: noarch
|
||||
|
||||
Requires: vim-enhanced
|
||||
Requires(post): vim-enhanced
|
||||
Requires(postun): vim-enhanced
|
||||
|
||||
# optional requirements
|
||||
# Critique Perl source code for best-practices
|
||||
Requires: perl(Perl::Critic)
|
||||
# Parses and beautifies perl source
|
||||
Requires: perl(Perl::Tidy)
|
||||
|
||||
# the following are not yet available in fedora
|
||||
# per-line Perl profiler
|
||||
#Requires: perl(Devel::SmallProf)
|
||||
# Perl debugger using a Tk GUI
|
||||
#Requires: perl(Devel::ptkdb)
|
||||
# Generate Ctags style tags for Perl source code
|
||||
#Requires: perl(Perl::Tags)
|
||||
# regular expression analyzer
|
||||
#Requires: perl(YAPE::Regex::Explain)
|
||||
|
||||
|
||||
%define vimfiles %{_datadir}/vim/vimfiles
|
||||
|
||||
%description
|
||||
Perl Support implements a Perl-IDE for Vim/gVim. It is written to considerably
|
||||
speed up writing code in a consistent style. This is done by inserting
|
||||
complete statements, comments, idioms, code snippets, templates, and POD
|
||||
documentation. Reading perldoc is integrated. Syntax checking, running a
|
||||
script, running perltidy, running perlcritics, starting a debugger and a
|
||||
profiler can be done with a keystroke.
|
||||
|
||||
|
||||
%prep
|
||||
%setup -q -c
|
||||
|
||||
# strip out false provides/requires from codesnippets
|
||||
cat << \EOF > %{name}-prov
|
||||
#!/bin/sh
|
||||
%{__perl_provides} $* |\
|
||||
sed -re '/perl\((Class|Package)Name/d'
|
||||
EOF
|
||||
%define __perl_provides %{_builddir}/%{name}-%{version}/%{name}-prov
|
||||
chmod +x %{__perl_provides}
|
||||
|
||||
cat << \EOF > %{name}-req
|
||||
#!/bin/sh
|
||||
%{__perl_requires} $* |\
|
||||
sed -re '/perl\((Class|base)/d'
|
||||
EOF
|
||||
%define __perl_requires %{_builddir}/%{name}-%{version}/%{name}-req
|
||||
chmod +x %{__perl_requires}
|
||||
|
||||
|
||||
%build
|
||||
# build is empty
|
||||
|
||||
|
||||
%install
|
||||
rm -rf %{buildroot}
|
||||
install -m 755 -d %{buildroot}%{vimfiles}/doc
|
||||
install -m 644 -p doc/*.txt %{buildroot}%{vimfiles}/doc
|
||||
install -m 755 -d %{buildroot}%{vimfiles}/ftplugin
|
||||
install -m 644 -p ftplugin/*.vim %{buildroot}%{vimfiles}/ftplugin
|
||||
install -m 755 -d %{buildroot}%{vimfiles}/plugin
|
||||
install -m 644 -p plugin/*.vim %{buildroot}%{vimfiles}/plugin
|
||||
install -m 755 -d %{buildroot}%{vimfiles}/perl-support/codesnippets
|
||||
install -m 644 -p perl-support/codesnippets/* \
|
||||
%{buildroot}%{vimfiles}/perl-support/codesnippets
|
||||
install -m 755 -d %{buildroot}%{vimfiles}/perl-support/templates
|
||||
install -m 644 -p perl-support/templates/* \
|
||||
%{buildroot}%{vimfiles}/perl-support/templates
|
||||
install -m 755 -d %{buildroot}%{vimfiles}/perl-support/modules
|
||||
install -m 644 -p perl-support/modules/* \
|
||||
%{buildroot}%{vimfiles}/perl-support/modules
|
||||
install -m 755 -d %{buildroot}%{vimfiles}/perl-support/scripts
|
||||
install -m 755 -p perl-support/scripts/*.{pl,sh} \
|
||||
%{buildroot}%{vimfiles}/perl-support/scripts
|
||||
install -m 644 -p perl-support/scripts/*.vim \
|
||||
%{buildroot}%{vimfiles}/perl-support/scripts
|
||||
install -m 755 -d %{buildroot}%{vimfiles}/perl-support/wordlists
|
||||
install -m 644 -p perl-support/wordlists/* \
|
||||
%{buildroot}%{vimfiles}/perl-support/wordlists
|
||||
|
||||
%clean
|
||||
rm -rf %{buildroot}
|
||||
|
||||
|
||||
%post
|
||||
umask 022
|
||||
cd %{_datadir}/vim/vimfiles/doc
|
||||
vim -u NONE -esX -c "helptags ." -c quit
|
||||
exit 0
|
||||
|
||||
|
||||
%postun
|
||||
if [ $1 -eq 0 ]; then
|
||||
umask 022
|
||||
cd %{_datadir}/vim/vimfiles/doc
|
||||
>tags
|
||||
vim -u NONE -esX -c "helptags ." -c quit
|
||||
fi
|
||||
exit 0
|
||||
|
||||
|
||||
%files
|
||||
%defattr(-,root,root,-)
|
||||
%doc README.perlsupport perl-support/doc/* perl-support/rc
|
||||
%{vimfiles}/perl-support
|
||||
%{vimfiles}/doc/perlsupport.txt
|
||||
%{vimfiles}/ftplugin/perl.vim
|
||||
%{vimfiles}/plugin/perl-support.vim
|
||||
|
||||
|
||||
%changelog
|
||||
* Fri Nov 28 2008 Iain Arnell <iarnell@gmail.com> 3.9.1-1
|
||||
- create vim-perl-support
|
||||
Loading…
Add table
Add a link
Reference in a new issue