Re: [gentoo-dev] [PATCH 3/3] texlive-common.eclass: Use nonfatal-respecting die for fmtutil-sys

2024-02-29 Thread Ulrich Mueller
> On Thu, 29 Feb 2024, Michał Górny wrote:

>> +"${EPREFIX}"/usr/bin/fmtutil-sys --all &> /dev/null \
>> +|| die -n "fmtutil-sys returned non-zero exit 
>> status ${res}"

> Put '||' at end of the line, then you won't need the redundant
> backslash.

I don't think we have such a policy, so || at end of line or beginning
of next line is really up to personal preference.

Independent of this, looks like ${res} is not defined?

Ulrich


signature.asc
Description: PGP signature


Re: [gentoo-dev] [PATCH 3/3] texlive-common.eclass: Use nonfatal-respecting die for fmtutil-sys

2024-02-29 Thread Michał Górny
On Thu, 2024-02-29 at 14:38 +0100, Florian Schmaus wrote:
> Signed-off-by: Florian Schmaus 
> ---
>  eclass/texlive-common.eclass | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/eclass/texlive-common.eclass b/eclass/texlive-common.eclass
> index 96e962cb8027..85cdb8ff204e 100644
> --- a/eclass/texlive-common.eclass
> +++ b/eclass/texlive-common.eclass
> @@ -199,7 +199,8 @@ efmtutil-sys() {
>   if has_version 'app-text/texlive-core' ; then
>   if [[ -z ${ROOT} && -x "${EPREFIX}"/usr/bin/fmtutil-sys ]] ; 
> then
>   einfo "Rebuilding formats"
> - "${EPREFIX}"/usr/bin/fmtutil-sys --all &> /dev/null || 
> die
> + "${EPREFIX}"/usr/bin/fmtutil-sys --all &> /dev/null \
> + || die -n "fmtutil-sys returned non-zero exit 
> status ${res}"

Put '||' at end of the line, then you won't need the redundant
backslash.

>   else
>   ewarn "Cannot run fmtutil-sys for some reason."
>   ewarn "Your formats might be inconsistent with your 
> installed ${PN} version"

-- 
Best regards,
Michał Górny



signature.asc
Description: This is a digitally signed message part


[gentoo-dev] [PATCH 3/3] texlive-common.eclass: Use nonfatal-respecting die for fmtutil-sys

2024-02-29 Thread Florian Schmaus
Signed-off-by: Florian Schmaus 
---
 eclass/texlive-common.eclass | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/eclass/texlive-common.eclass b/eclass/texlive-common.eclass
index 96e962cb8027..85cdb8ff204e 100644
--- a/eclass/texlive-common.eclass
+++ b/eclass/texlive-common.eclass
@@ -199,7 +199,8 @@ efmtutil-sys() {
if has_version 'app-text/texlive-core' ; then
if [[ -z ${ROOT} && -x "${EPREFIX}"/usr/bin/fmtutil-sys ]] ; 
then
einfo "Rebuilding formats"
-   "${EPREFIX}"/usr/bin/fmtutil-sys --all &> /dev/null || 
die
+   "${EPREFIX}"/usr/bin/fmtutil-sys --all &> /dev/null \
+   || die -n "fmtutil-sys returned non-zero exit 
status ${res}"
else
ewarn "Cannot run fmtutil-sys for some reason."
ewarn "Your formats might be inconsistent with your 
installed ${PN} version"
-- 
2.43.0