public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: Leo Sandoval <lsandova@redhat.com>
To: git-commits@fedoraproject.org
Subject: [rpms/grub2] rawhide: spec: always exit with zero status on common posttrans scriptlet
Date: Thu, 18 Jun 2026 08:04:39 GMT	[thread overview]
Message-ID: <178176987963.1.10087020406301374311.rpms-grub2-7b051a1f0edb@fedoraproject.org> (raw)

            A new commit has been pushed.

            Repo   : rpms/grub2
            Branch : rawhide
            Commit : 7b051a1f0edb3417419477815e3cd838a86e19c9
            Author : Leo Sandoval <lsandova@redhat.com>
            Date   : 2026-06-17T10:31:22-06:00
            Stats  : +6/-4 in 1 file(s)
            URL    : https://src.fedoraproject.org/rpms/grub2/c/7b051a1f0edb3417419477815e3cd838a86e19c9?branch=rawhide

            Log:
            spec: always exit with zero status on common posttrans scriptlet

The parent commit discovered a common posttrans issue when executing
the grub2-mkconfig, where internally it probes /boot/efi folder and fails
under some chroot (or similar) environments. This is not a critical
error so explicity return zero on this case through the common '||
true' script pattern.

Signed-off-by: Leo Sandoval <lsandova@redhat.com>

---
diff --git a/grub2.spec b/grub2.spec
index e6a71f2..8665d22 100644
--- a/grub2.spec
+++ b/grub2.spec
@@ -17,7 +17,7 @@
 Name:		grub2
 Epoch:		1
 Version:	2.12
-Release:	64%{?dist}
+Release:	65%{?dist}
 Summary:	Bootloader with support for Linux, Multiboot and more
 License:	GPL-3.0-or-later
 URL:		http://www.gnu.org/software/grub/
@@ -404,13 +404,13 @@ GRUB_DIR=/boot/grub2
 
 if test ! -f ${GRUB_DIR}/grub.cfg; then
     # there's no config in GRUB home, create one
-    grub2-mkconfig -o ${GRUB_DIR}/grub.cfg
+    grub2-mkconfig -o ${GRUB_DIR}/grub.cfg  || :
 else
     GRUB_CFG_MODE=$(stat --format="%a" ${GRUB_DIR}/grub.cfg)
     if ! test "${GRUB_CFG_MODE}" = "600"; then
         # when upgrading from <=2.06-126 to newer versions, the grub config stub
         # may have different mode than 0600, so set the latter if this is the case
-        chmod 0600 ${GRUB_DIR}/grub.cfg
+        chmod 0600 ${GRUB_DIR}/grub.cfg || :
     fi
 fi
 
@@ -627,7 +627,9 @@ fi
 %endif
 
 %changelog
-=======
+* Mon Jun 15 2026 Leo Sandoval <lsandova@redhat.com> - 2.12-65
+- spec: always exit with zero status on common posttrans scriptlet
+
 * Mon Jun 15 2026 Leo Sandoval <lsandova@redhat.com> - 2.12-64
 - spec: move all pending EFI logic from common to EFI package
 - Related: #2482790

                 reply	other threads:[~2026-06-18  8:04 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=178176987963.1.10087020406301374311.rpms-grub2-7b051a1f0edb@fedoraproject.org \
    --to=lsandova@redhat.com \
    --cc=git-commits@fedoraproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox