# Generated from more_ruby-0.2.4.gem by gem2rpm -*- rpm-spec -*-
%global gem_name more_ruby

Name: rubygem-%{gem_name}
Version: 0.2.4
Release: 1%{?dist}
Summary: Adds some extra methods to some Ruby standard classes
License: MIT
URL: https://github.com/RMorrisby/more_ruby
Source0: https://rubygems.org/gems/%{gem_name}-%{version}.gem
BuildRequires: ruby(release)
BuildRequires: rubygems-devel
BuildRequires: ruby >= 1.9
BuildArch: noarch

%description
A very simple gem that adds some methods to some Ruby standard classes, e.g.
<array>.include_any?, <array>.delete_random, etc.
Simply require the gem ( require "more_ruby" ) and the additional methods will
be available.
# New instance methods #
## Array
:all_instance_of?, :all_kind_of?, :av, :delete_random, :include_any?,
:insert_flat, :mean, :modulo_fetch, :peach, :random, :random_index,
:random_insert, :random_move, :stringify_all_values_deep, :sum, :wrap_fetch
## Fixnum
:digit_count, :format_with_thousands_delimiter, :num_to_letter, :signif
## Float
:format_with_thousands_delimiter, :signif
## Hash
:all_keys, :all_values, :delete_random, :peach, :random_key, :random_pair,
:random_value, :remove_empty_fields, :sort_deep, :stringify_all_values_deep,
:strip_hash_of_keys, :to_a_deep, :to_xml
## Integer
:digit_count, :format_with_thousands_delimiter, :signif
## NilClass
:empty?
## Numeric
:format_with_thousands_delimiter
## String
:append, :camelcase, :camelcase_to_snakecase, :capitalize_all,
:capitalize_first_letter_only, :escape, :escape_whitespace,
:extract_values_from_xml_string, :formatted_number, :index_of_last_capital,
:invert_case, :is_hex?, :is_integer?, :join, :pascalcase, :prefix_lines,
:random_case, :snakecase, :snakecase_and_downcase, :to_bool, :unindent
## Time
:is_after?, :is_before?, :is_within?, :remove_subseconds
# New singleton methods #
## FalseClass
:maybe?, :random
## File
:basename_no_ext
## TrueClass
:maybe?, :random.
.


%package doc
Summary: Documentation for %{name}
Requires: %{name} = %{version}-%{release}
BuildArch: noarch

%description doc
Documentation for %{name}.

%prep
%setup -q -n %{gem_name}-%{version}

%build
# Create the gem as gem install only works on a gem file
gem build ../%{gem_name}-%{version}.gemspec

# %%gem_install compiles any C extensions and installs the gem into ./%%gem_dir
# by default, so that we can move it into the buildroot in %%install
%gem_install

%install
mkdir -p %{buildroot}%{gem_dir}
cp -a .%{gem_dir}/* \
        %{buildroot}%{gem_dir}/



%check
pushd .%{gem_instdir}
# Run the test suite.
popd

%files
%dir %{gem_instdir}
%license %{gem_instdir}/LICENCE.txt
%{gem_libdir}
%exclude %{gem_cache}
%{gem_spec}

%files doc
%doc %{gem_docdir}
%doc %{gem_instdir}/README.md
%{gem_instdir}/test

%changelog
* Tue Sep 14 2021 mockbuilder - 0.2.4-1
- Initial package