[rubygem-mixlib-shellout] Initial import of rubygem-mixlib-shellout (bz#823337)

Julian C. Dunn jdunn at fedoraproject.org
Thu Dec 20 16:27:16 UTC 2012


commit 22861f58a9cdfd7dff1f80c739d2bffb85ad877d
Author: Julian C. Dunn <jdunn at aquezada.com>
Date:   Thu Dec 20 11:26:31 2012 -0500

    Initial import of rubygem-mixlib-shellout (bz#823337)

 .gitignore                                 |    2 +
 mixlib-shellout-awesomeprint-removal.patch |   27 +++++++
 mixlib-shellout-usrmove.patch              |   13 ++++
 rubygem-mixlib-shellout.spec               |  109 ++++++++++++++++++++++++++++
 sources                                    |    2 +
 5 files changed, 153 insertions(+), 0 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index e69de29..c45eab8 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1,2 @@
+/mixlib-shellout-1.1.0.gem
+/rubygem-mixlib-shellout-1.1.0-specs.tgz
diff --git a/mixlib-shellout-awesomeprint-removal.patch b/mixlib-shellout-awesomeprint-removal.patch
new file mode 100644
index 0000000..4e0f4c3
--- /dev/null
+++ b/mixlib-shellout-awesomeprint-removal.patch
@@ -0,0 +1,27 @@
+diff --git a/spec/mixlib/shellout_spec.rb b/spec/mixlib/shellout_spec.rb
+index cc59829..5d2c93d 100644
+--- a/spec/mixlib/shellout_spec.rb
++++ b/spec/mixlib/shellout_spec.rb
+@@ -422,7 +422,6 @@ describe Mixlib::ShellOut do
+             end
+ 
+             context 'when not using a batch file' do
+-              let(:watch) { lambda { |a| ap a } }
+               let(:cmd) { "#{executable_file_name} #{script_name}" }
+ 
+               let(:executable_file_name) { "\"#{dir}/Ruby Parser.exe\"".tap(&make_executable!) }
+diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb
+index 0eab6ba..23908f3 100644
+--- a/spec/spec_helper.rb
++++ b/spec/spec_helper.rb
+@@ -6,10 +6,6 @@ require 'tmpdir'
+ require 'tempfile'
+ require 'timeout'
+ 
+-require 'ap'
+-
+-WATCH = lambda { |x| ap x } unless defined?(WATCH)
+-
+ # Load everything from spec/support
+ # Do not change the gsub.
+ Dir["spec/support/**/*.rb"].map { |f| f.gsub(%r{.rb$}, '') }.each { |f| require f }
diff --git a/mixlib-shellout-usrmove.patch b/mixlib-shellout-usrmove.patch
new file mode 100644
index 0000000..dccebc5
--- /dev/null
+++ b/mixlib-shellout-usrmove.patch
@@ -0,0 +1,13 @@
+diff --git a/spec/mixlib/shellout_spec.rb b/spec/mixlib/shellout_spec.rb
+index cc59829..cecd585 100644
+--- a/spec/mixlib/shellout_spec.rb
++++ b/spec/mixlib/shellout_spec.rb
+@@ -298,7 +298,7 @@ describe Mixlib::ShellOut do
+       let(:options) { { :cwd => cwd } }
+ 
+       context 'when running under Unix', :unix_only do
+-        let(:cwd) { '/bin' }
++        let(:cwd) { '/tmp' }
+         let(:cmd) { 'pwd' }
+ 
+         it "should chdir to the working directory" do
diff --git a/rubygem-mixlib-shellout.spec b/rubygem-mixlib-shellout.spec
new file mode 100644
index 0000000..c2f1936
--- /dev/null
+++ b/rubygem-mixlib-shellout.spec
@@ -0,0 +1,109 @@
+# Generated from mixlib-shellout-1.0.0.gem by gem2rpm -*- rpm-spec -*-
+%global gem_name mixlib-shellout
+# EPEL6 lacks rubygems-devel package that provides these macros
+%if %{?el6}0
+%global gem_dir %(ruby -rubygems -e 'puts Gem::dir' 2>/dev/null)
+%global gem_instdir %{gem_dir}/gems/%{gem_name}-%{version}
+%global gem_docdir %{gem_dir}/doc/%{gem_name}-%{version}
+%global gem_libdir %{gem_instdir}/lib
+%global gem_cache %{gem_dir}/cache/%{gem_name}-%{version}.gem
+%global gem_spec %{gem_dir}/specifications/%{gem_name}-%{version}.gemspec
+%endif
+
+%if %{?el6}0 || %{?fc16}0
+%global rubyabi 1.8
+%else
+%global rubyabi 1.9.1
+%endif
+
+Summary: Run external commands on Unix or Windows
+Name: rubygem-%{gem_name}
+Version: 1.1.0
+Release: 3%{?dist}
+Group: Development/Languages
+License: ASL 2.0
+URL: https://github.com/opscode/mixlib-shellout
+Source0: http://rubygems.org/gems/%{gem_name}-%{version}.gem
+# Tests for this package are not in the gem. To update:
+# git clone https://github.com/opscode/mixlib-shellout.git && cd mixlib-shellout
+# git checkout 1.1.0
+# tar czvf rubygem-mixlib-shellout-1.1.0-specs.tgz spec/
+Source1: rubygem-%{gem_name}-%{version}-specs.tgz
+# Patch for UsrMove, see http://tickets.opscode.com/browse/MIXLIB-6
+Patch0: mixlib-shellout-usrmove.patch
+# Patch for removal of awesomeprint, see http://tickets.opscode.com/browse/MIXLIB-7
+Patch1: mixlib-shellout-awesomeprint-removal.patch
+
+Requires: ruby(abi) = %{rubyabi}
+Requires: ruby(rubygems)
+BuildRequires: ruby(abi) = %{rubyabi}
+%{!?el6:BuildRequires: rubygem(rspec)}
+%{!?el6:BuildRequires: rubygems-devel}
+BuildArch: noarch
+Provides: rubygem(%{gem_name}) = %{version}
+
+%description
+Run external commands on Unix or Windows
+
+%package doc
+Summary: Documentation for %{name}
+Group: Documentation
+Requires: %{name} = %{version}-%{release}
+BuildArch: noarch
+
+%description doc
+Documentation for %{name}
+
+%prep
+%setup -q -c -T
+mkdir -p .%{gem_dir}
+gem install --local --install-dir .%{gem_dir} \
+            --force %{SOURCE0}
+
+%build
+
+%install
+mkdir -p %{buildroot}%{gem_dir}
+cp -a .%{gem_dir}/* \
+        %{buildroot}%{gem_dir}/
+
+%check
+pushd .%{gem_instdir}
+tar zxvf %{SOURCE1}
+patch -p1 < %{PATCH0}
+patch -p1 < %{PATCH1}
+# One of the tests involves a fork && sleep 10 that may not finish before mock
+rspec && sleep 10
+popd
+
+%files
+%doc %{gem_instdir}/README.md
+%doc %{gem_instdir}/LICENSE
+%dir %{gem_instdir}
+%{gem_libdir}
+%exclude %{gem_cache}
+%{gem_spec}
+
+%files doc
+%doc %{gem_docdir}
+
+%changelog
+* Thu Dec 20 2012 Julian C. Dunn <jdunn at aquezada.com> - 1.1.0-3
+- fix incorrect ruby(abi) requires
+
+* Tue Dec 18 2012 Julian C. Dunn <jdunn at aquezada.com> - 1.1.0-2
+- add patches for rspec test issues on Fedora
+
+* Sun Oct 21 2012 Julian C. Dunn <jdunn at aquezada.com> - 1.1.0-1
+- rebuild with 1.1.0
+
+* Sun Jun 17 2012 Jonas Courteau <rpms at courteau.org> - 1.0.0-3
+- move all test-related operations into check
+- excluding gem_cache
+
+* Sun Jun 3 2012 Jonas Courteau <rpms at courteau.org> - 1.0.0-2
+- exclude specs from final package
+- link to upstream bug reports for missing specs, broken test
+
+* Sat May 12 2012  Jonas Courteau <rpms at courteau.org> - 1.0.0-1
+- Initial package
diff --git a/sources b/sources
index e69de29..48ef1d7 100644
--- a/sources
+++ b/sources
@@ -0,0 +1,2 @@
+94d5aedb7c30a7b10d3b0da03bc4d62a  mixlib-shellout-1.1.0.gem
+60630f23b9a4da1036f3fd8c33e47585  rubygem-mixlib-shellout-1.1.0-specs.tgz


More information about the scm-commits mailing list