Blob Blame History Raw
Name:           perl-File-pushd
Version:        1.00
Release:        0.3.1%{?dist}
Summary:        Change directory temporarily for a limited scope
License:        ASL 2.0
Group:          Development/Libraries
URL:            http://search.cpan.org/dist/File-pushd/
Source0:        http://www.cpan.org/authors/id/D/DA/DAGOLDEN/File-pushd-%{version}.tar.gz
BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildArch:      noarch
BuildRequires:  perl(Module::Build)
BuildRequires:  perl(Test::More) >= 0.45
Requires:       perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))

%description
File::pushd does a temporary chdir that is easily and automatically
reverted, similar to pushd in some Unix command shells. It works by
creating an object that caches the original working directory. When the
object is destroyed, the destructor calls chdir to revert to the original
working directory. By storing the object in a lexical variable with a
limited scope, this happens automatically at the end of the scope.

%prep
%setup -q -n File-pushd-%{version}

%build
%{__perl} Build.PL installdirs=vendor
./Build

%install
rm -rf $RPM_BUILD_ROOT

./Build install destdir=$RPM_BUILD_ROOT create_packlist=0
find $RPM_BUILD_ROOT -depth -type d -exec rmdir {} 2>/dev/null \;

%{_fixperms} $RPM_BUILD_ROOT/*

%check
./Build test

%clean
rm -rf $RPM_BUILD_ROOT

%files
%defattr(-,root,root,-)
%doc Changes LICENSE README Todo
%{perl_vendorlib}/*
%{_mandir}/man3/*

%changelog
* Tue Jun 21 2011 Marcela Mašláňová <mmaslano@redhat.com> 1.00-0.3.1
- package was added to EPEL and has a 0 leading version to keep it older than RHEL.
- Related: rhbz#479669

* Fri Jan 22 2010 Dennis Gregorovic <dgregor@redhat.com> - 1.00-3.1
- Rebuilt for RHEL 6
Related: rhbz#543948

* Thu Jul 02 2009 Jeff Fearn <jfearn@redhat.com> - 1.00-3
- bump for RHEL

* Thu Feb 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.00-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild

* Mon Jan 12 2009 Marcela Mašláňová <mmaslano@redhat.com> 1.00-1
- Specfile autogenerated by cpanspec 1.77.