[EMAIL PROTECTED] wrote:
> Alexander E. Patrakov wrote:
>> Feature request: don't hardcode target numbers. E.g., in my UTF-8
>> book, a new package (gdbm) has been added, thus causing number skew
>> for all packages after it. Thus, constructions of the following form
>> fail:
>>
>> if [ "$i" = "082-groff" ] ; then {do something} ; fi.
>>
>> Until this is fixed, I can't make my UTF-8 book compatible with
>> jhalfs.
>>
>> BTW, a similar problem will appear soon in trunk due to removal of
>> hotplug.
>>
>
> Yep, I completely agree. The line above, for example, could probably
> read:
>
> if echo $i | grep -q "groff" ; then ... ; fi
>
> Other suggestions are welcome.
I'd suggest something like this:
if [ ${string: -5} = "groff" ] ; then {do something} ; fi
Dave :)
--
http://linuxfromscratch.org/mailman/listinfo/lfs-dev
FAQ: http://www.linuxfromscratch.org/faq/
Unsubscribe: See the above information page