File vim-plugin-perl-support.spec of Package vim-plugin-perl-support

# spec file for package vim-plugin-perl-support
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via

%define         vimplugin_dir %{_datadir}/vim/vimfiles
Name:           vim-plugin-perl-support
Version:        5.2
Release:        0
Summary:        Write and run Perl-scripts using menus and hotkeys
License:        GPL-2.0-only
Group:          Productivity/Text/Editors
BuildRequires:  unzip
BuildRequires:  vim
BuildRequires:  vim-data
Requires:       vim
Recommends:     perl(Perl::Critic)
Recommends:     perl(Perl::Tidy)

- insert various types of comments
- insert complete but empty statements (e.g. 'if {} else {}' )
- insert often used code snippets (e.g. declarations, the opening of files, .. )
- insert the names of file tests, character classes, special Perl-variables and POSIX-signals
- read, write, maintain your own code snippets in a separate   directory
- run scripts or run syntax check from within the editor
- show compilation erros in a quickfix window; navigate with hotkeys
- read perldoc for functions and modules
- run perltidy / run the profiler SmallProf
- test / explain regular expressions (needs Vim with Perl interface)

This plugin comes with a help file (perlsupport.txt). Read it with

  :h perlsupport

Author Fritz Mehner

%setup -q -c %{name}


install -m 755 -d %{buildroot}%{vimplugin_dir}/doc
install -m 644 -p doc/*.txt %{buildroot}%{vimplugin_dir}/doc

install -m 755 -d %{buildroot}%{vimplugin_dir}/syntax
install -m 644 -p syntax/template.vim %{buildroot}%{vimplugin_dir}/syntax

install -m 755 -d %{buildroot}%{vimplugin_dir}/ftplugin
install -m 644 -p ftplugin/*.vim %{buildroot}%{vimplugin_dir}/ftplugin

install -m 755 -d %{buildroot}%{vimplugin_dir}/plugin
install -m 644 -p plugin/*.vim %{buildroot}%{vimplugin_dir}/plugin

install -m 755 -d %{buildroot}%{vimplugin_dir}/perl-support

install -m 755 -d %{buildroot}%{vimplugin_dir}/perl-support/codesnippets/RegularExpressions
install -m 644 -p perl-support/codesnippets/RegularExpressions/* \

install -m 755 -d %{buildroot}%{vimplugin_dir}/perl-support/codesnippets
install -m 644 -p perl-support/codesnippets/*.pl \
install -m 644 -p perl-support/codesnippets/dot.SmallProf \
install -m 644 -p perl-support/codesnippets/free-software-comment \

install -m 755 -d %{buildroot}%{vimplugin_dir}/perl-support/templates
install -m 644 -p perl-support/templates/* \

install -m 755 -d %{buildroot}%{vimplugin_dir}/perl-support/modules
install -m 644 -p perl-support/modules/* \

install -m 755 -d %{buildroot}%{vimplugin_dir}/perl-support/scripts
install -m 755 -p perl-support/scripts/*.{pl,sh} \

install -m 755 -d %{buildroot}%{vimplugin_dir}/perl-support/wordlists
install -m 644 -p perl-support/wordlists/* \

vim -u NONE -U NONE -X -n '+set nobackup nomore' '+helptags %{buildroot}%{vimplugin_dir}/doc' '+qa!' </dev/null &>/dev/null

if [[ $1 == 0 ]]
  vim -u NONE -U NONE -X -n '+set nobackup nomore' '+helptags %{buildroot}%{vimplugin_dir}/doc' '+qa!' </dev/null &>/dev/null

%doc %{vimplugin_dir}/doc
%doc perl-support/doc/*
%doc perl-support/rc
%doc perl-support/README.perlsupport

openSUSE Build Service is sponsored by