Skip to content

Instantly share code, notes, and snippets.

@pvalena
Created January 11, 2024 06:30
Show Gist options
  • Save pvalena/cdb9486f94d43dc00bb18c01153c95e0 to your computer and use it in GitHub Desktop.
Save pvalena/cdb9486f94d43dc00bb18c01153c95e0 to your computer and use it in GitHub Desktop.
--> Please check the gem compare output bellow: !
grep: warning: stray \ before :
NOTE: Gem::Specification#has_rdoc is deprecated with no replacement. It will be removed in Rubygems 4
Gem::Specification#has_rdoc called from /usr/share/gems/gems/gem-compare-0.0.7/lib/rubygems/comparator/utils.rb:112.
NOTE: Gem::Specification#has_rdoc is deprecated with no replacement. It will be removed in Rubygems 4
Gem::Specification#has_rdoc called from /usr/share/gems/gems/gem-compare-0.0.7/lib/rubygems/comparator/utils.rb:112.
commit c6fed26d2f268a72f43bfdab0e001310b699499f
Author: Pavel Valena <[email protected]>
Date: Tue Oct 3 12:46:59 2023 +0200
Update to safe_yaml 1.0.5
also enhance .spec and .gitignore files.
Resolves: rhbz#1680163
diff --git a/.gitignore b/.gitignore
index 945281c..1e95655 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,4 +1 @@
-/safe_yaml-0.9.4.gem
-/safe_yaml-1.0.1.gem
-/safe_yaml-1.0.3.gem
-/safe_yaml-1.0.4.gem
+/safe_yaml-*.gem
diff --git a/rubygem-safe_yaml.spec b/rubygem-safe_yaml.spec
index 3d4b154..6b02c88 100644
--- a/rubygem-safe_yaml.spec
+++ b/rubygem-safe_yaml.spec
@@ -5,14 +5,11 @@
Summary: Parse YAML safely
Name: rubygem-%{gem_name}
-Version: 1.0.4
-Release: 18%{?dist}
+Version: 1.0.5
+Release: 1%{?dist}
License: MIT
URL: http://dtao.github.com/safe_yaml/
Source0: https://rubygems.org/gems/%{gem_name}-%{version}.gem
-# Fix Ruby 2.5 compatibility.
-# https://github.com/dtao/safe_yaml/pull/90
-Patch0: rubygem-safe_yaml-1.0.4-Fix-uninitialized-constant-DateTime.patch
BuildRequires: ruby(release)
BuildRequires: rubygems-devel
%if 0%{?enable_tests}
@@ -39,14 +36,10 @@ BuildArch: noarch
Documentation for %{name}
%prep
-gem unpack %{SOURCE0}
-%setup -q -D -T -n %{gem_name}-%{version}
-gem spec %{SOURCE0} -l --ruby > %{gem_name}.gemspec
-
-%patch0 -p1
+%setup -q -n %{gem_name}-%{version}
%build
-gem build %{gem_name}.gemspec
+gem build ../%{gem_name}-%{version}.gemspec
%gem_install
%install
@@ -58,11 +51,6 @@ cp -a ./%{_bindir}/* %{buildroot}%{_bindir}
find %{buildroot}%{gem_instdir}/bin -type f | xargs chmod a+x
-# Remove build leftovers.
-rm -rf %{buildroot}%{gem_instdir}/{.rvmrc,.document,.require_paths,.gitignore,.travis.yml,.rspec,.gemtest,.yard*}
-rm -rf %{buildroot}%{gem_instdir}/%{gem_name}.gemspec
-rm -rf %{buildroot}%{gem_instdir}/bundle_install_all_ruby_versions.sh
-
%if 0%{?enable_tests}
%check
pushd .%{gem_instdir}
@@ -78,6 +66,8 @@ popd
%{gem_libdir}
%exclude %{gem_cache}
%{gem_spec}
+%exclude %{gem_instdir}/.*
+%exclude %{gem_instdir}/bundle_install_all_ruby_versions.sh
%files doc
%doc %{gem_instdir}/CHANGES.md
@@ -87,10 +77,13 @@ popd
%{gem_instdir}/Gemfile
%{gem_instdir}/run_specs_all_ruby_versions.sh
%{gem_instdir}/spec
-
-
+%{gem_instdir}/%{gem_name}.gemspec
%changelog
+* Tue Oct 03 2023 Pavel Valena <[email protected]> - 1.0.5-1
+- Update to safe_yaml 1.0.5.
+ Resolves: rhbz#1680163
+
* Fri Jul 21 2023 Fedora Release Engineering <[email protected]> - 1.0.4-18
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
diff --git a/sources b/sources
index e069e3c..1f63b1e 100644
--- a/sources
+++ b/sources
@@ -1 +1 @@
-a92204c1caa87816c0d1c72bd8419c90 safe_yaml-1.0.4.gem
+SHA512 (safe_yaml-1.0.5.gem) = d9c8d9c28c3c8708f97cb0545f58152af81056f5e79147424dd7bf625f8e533440d1ed41d6abe2faf84578754823a1215ba28772c2e8593bfcfc397d647187b9
On branch rebase
Your branch is up to date with 'pvalena/rebase'.
nothing to commit (use -u to show untracked files)
Everything up-to-date
branch 'rebase' set up to track 'pvalena/rebase'.
> Run copr build.
+ scripts/pkgs/cr-build.sh -c -t 30m rubygems
Created builds: 6881257
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment