1 |
Roy Marples ha scritto: |
2 |
> On Tue, 2007-10-09 at 13:17 +0200, Alexis Ballier wrote: |
3 |
> |
4 |
>>> if [ "${f/config/}" != "${f}" ] |
5 |
>>> Should be |
6 |
>>> if [ "${f#*config*}" != "${f}" ] |
7 |
>>> |
8 |
Should be |
9 |
|
10 |
if [ "${f#*config}" != "${f}" ] |
11 |
|
12 |
the 2nd asterisk is not needed, symmetry apart |
13 |
|
14 |
|
15 |
>> changed that one, the "semantics" looks better indeed; what is wanted |
16 |
>> here is to exclude $f containing "config". Am I missing something when |
17 |
>> I understand it as the exact same thing but more readable ? |
18 |
>> |
19 |
> |
20 |
> The former is bash specific, the later is POSIX. Both do different |
21 |
> things though. |
22 |
> |
23 |
> Thanks |
24 |
> |
25 |
> Roy |
26 |
> |
27 |
> |
28 |
|
29 |
-- |
30 |
gentoo-dev@g.o mailing list |