Re: [gentoo-dev] [PATCH] l10n.eclass: Sort and normalize PLOCALES in l10n_find_plocales_change

2016-05-08 Thread James Le Cuirot
On Sun, 8 May 2016 11:20:34 -0400 Michael Orlitzky wrote: > On 05/07/2016 04:13 PM, James Le Cuirot wrote: > > > > + if [[ $(tr -s "[:space:]" "\n" <<< "${PLOCALES}" | sort | > > xargs echo) != ${current%[[:space:]]} ]] ; then > > The stuff on the left-hand side just sorts

Re: [gentoo-dev] [PATCH] l10n.eclass: Sort and normalize PLOCALES in l10n_find_plocales_change

2016-05-08 Thread Michael Orlitzky
On 05/07/2016 04:13 PM, James Le Cuirot wrote: > > + if [[ $(tr -s "[:space:]" "\n" <<< "${PLOCALES}" | sort | xargs echo) > != ${current%[[:space:]]} ]] ; then The stuff on the left-hand side just sorts a space-separated list, right? It might be time to split that into another function. It

Re: [gentoo-dev] [PATCH] l10n.eclass: Sort and normalize PLOCALES in l10n_find_plocales_change

2016-05-07 Thread Davide Pesavento
On Sat, May 7, 2016 at 11:23 PM, James Le Cuirot wrote: > On Sat, 7 May 2016 23:13:11 +0200 > Davide Pesavento wrote: > >> On Sat, May 7, 2016 at 10:13 PM, James Le Cuirot >> wrote: >> > l10n_find_plocales_change assumes that PLOCALES is

Re: [gentoo-dev] [PATCH] l10n.eclass: Sort and normalize PLOCALES in l10n_find_plocales_change

2016-05-07 Thread James Le Cuirot
On Sat, 7 May 2016 23:13:11 +0200 Davide Pesavento wrote: > On Sat, May 7, 2016 at 10:13 PM, James Le Cuirot > wrote: > > l10n_find_plocales_change assumes that PLOCALES is sorted > > alphanumerically with a single space between each entry and no > >

Re: [gentoo-dev] [PATCH] l10n.eclass: Sort and normalize PLOCALES in l10n_find_plocales_change

2016-05-07 Thread Davide Pesavento
On Sat, May 7, 2016 at 10:13 PM, James Le Cuirot wrote: > l10n_find_plocales_change assumes that PLOCALES is sorted > alphanumerically with a single space between each entry and no > surrounding whitespace. This is not a bad assumption but it isn't > documented and it's

[gentoo-dev] [PATCH] l10n.eclass: Sort and normalize PLOCALES in l10n_find_plocales_change

2016-05-07 Thread James Le Cuirot
l10n_find_plocales_change assumes that PLOCALES is sorted alphanumerically with a single space between each entry and no surrounding whitespace. This is not a bad assumption but it isn't documented and it's inconvenient in at least one particular case. MakeMKV uses non-standard locale names and I