Re: [PATCH] Fix bootstrap check for po directory

Leo Sandoval via Grub-devel <[email protected]> Tue, 17 Mar 2026 14:59:33 -0600
Newsgroups org.gnu.grub-devel
Message-ID <CACF7NTiW3yCp+1pDvU22OT1L98e_Nq32E4SqEX7=-mQqEQMb4w@mail.gmail.com>
--===============5211303453080826149==
Content-Type: multipart/alternative; boundary="00000000000065c9af064d3e9df1"

--00000000000065c9af064d3e9df1
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

Azban,

Can you create a PR on freedesktop? I am working on a CONTRIBUTING file but
for the moment please refer to the email sent recently

https://lists.gnu.org/archive/html/grub-devel/2026-03/msg00036.html



On Mon, Mar 16, 2026 at 6:35=E2=80=AFAM azban <[email protected]> wrote:

> The syntax for the check here was incorrect. If the directory didn't
> exist, it would create it, but if it did exist, it would not return and i=
t
> would redownload.
>
> diff --git a/bootstrap b/bootstrap
> index dc9fb4383..1d9c6a70f 100755
> --- a/bootstrap
> +++ b/bootstrap
> @@ -931,7 +931,7 @@ update_po_files() {
>    # Usually contains *.s1 checksum files.
>    ref_po_dir=3D"$po_dir/.reference"
>
> -  test -d $ref_po_dir || mkdir $ref_po_dir || return
> +  test -d $ref_po_dir && return || mkdir $ref_po_dir
>    download_po_files $ref_po_dir $domain \
>      && ls "$ref_po_dir"/*.po 2>/dev/null |
>        sed 's|.*/||; s|\.po$||' > "$po_dir/LINGUAS" || return
>
> _______________________________________________
> Grub-devel mailing list
> [email protected]
> https://lists.gnu.org/mailman/listinfo/grub-devel
>

--00000000000065c9af064d3e9df1
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr">Azban,=C2=A0<div><br><div>Can you create a PR on freedeskt=
op? I am working on a CONTRIBUTING file but for the moment please refer to =
the email sent recently</div><div><br></div><div><a href=3D"https://lists.g=
nu.org/archive/html/grub-devel/2026-03/msg00036.html">https://lists.gnu.org=
/archive/html/grub-devel/2026-03/msg00036.html</a><br><div><br></div><div><=
br></div></div></div></div><br><div class=3D"gmail_quote gmail_quote_contai=
ner"><div dir=3D"ltr" class=3D"gmail_attr">On Mon, Mar 16, 2026 at 6:35=E2=
=80=AFAM azban &lt;<a href=3D"mailto:[email protected]">[email protected]</a>&gt; wro=
te:<br></div><blockquote class=3D"gmail_quote" style=3D"margin:0px 0px 0px =
0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">The syntax f=
or the check here was incorrect. If the directory didn&#39;t exist, it woul=
d create it, but if it did exist, it would not return and it would redownlo=
ad.<br>
<br>
diff --git a/bootstrap b/bootstrap<br>
index dc9fb4383..1d9c6a70f 100755<br>
--- a/bootstrap<br>
+++ b/bootstrap<br>
@@ -931,7 +931,7 @@ update_po_files() {<br>
=C2=A0 =C2=A0# Usually contains *.s1 checksum files.<br>
=C2=A0 =C2=A0ref_po_dir=3D&quot;$po_dir/.reference&quot;<br>
<br>
-=C2=A0 test -d $ref_po_dir || mkdir $ref_po_dir || return<br>
+=C2=A0 test -d $ref_po_dir &amp;&amp; return || mkdir $ref_po_dir<br>
=C2=A0 =C2=A0download_po_files $ref_po_dir $domain \<br>
=C2=A0 =C2=A0 =C2=A0&amp;&amp; ls &quot;$ref_po_dir&quot;/*.po 2&gt;/dev/nu=
ll |<br>
=C2=A0 =C2=A0 =C2=A0 =C2=A0sed &#39;s|.*/||; s|\.po$||&#39; &gt; &quot;$po_=
dir/LINGUAS&quot; || return<br>
<br>
_______________________________________________<br>
Grub-devel mailing list<br>
<a href=3D"mailto:[email protected]" target=3D"_blank">[email protected]<=
/a><br>
<a href=3D"https://lists.gnu.org/mailman/listinfo/grub-devel" rel=3D"norefe=
rrer" target=3D"_blank">https://lists.gnu.org/mailman/listinfo/grub-devel</=
a><br>
</blockquote></div>

--00000000000065c9af064d3e9df1--



--===============5211303453080826149==
Content-Type: text/plain; charset="utf-8"
MIME-Version: 1.0
Content-Transfer-Encoding: base64
Content-Disposition: inline

X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX18KR3J1Yi1kZXZl
bCBtYWlsaW5nIGxpc3QKR3J1Yi1kZXZlbEBnbnUub3JnCmh0dHBzOi8vbGlzdHMuZ251Lm9yZy9t
YWlsbWFuL2xpc3RpbmZvL2dydWItZGV2ZWwK

--===============5211303453080826149==--