1 |
2011/7/3 Paul Arthur <junk+usenet@×××××××××××.com>: |
2 |
> On 2011-07-03, Jonathan Callen <abcd@g.o> wrote: |
3 |
>> Peter Volkov wrote: |
4 |
>>>> |
5 |
>>>> rm -rf "${D}/usr/share/doc/aria2" |
6 |
>>> |
7 |
>>> || die |
8 |
>> |
9 |
>> `rm -f` never fails -- if the target does not exist, then rm simply returns |
10 |
>> true. (The only reason it would fail that I can think of is /bin/rm not |
11 |
>> existing, in which case you have a bigger problem.) |
12 |
>> |
13 |
>> To test, try `rm -f /nonexistant/file; echo $?` |
14 |
> |
15 |
> jill-zeke /var/tmp $ rm -f testfile |
16 |
> rm: cannot remove `testfile': Operation not permitted |
17 |
> jill-zeke /var/tmp $ echo $? |
18 |
> 1 |
19 |
|
20 |
rm -f "chuck norris" |
21 |
rm: cannot remove `Chuck Norris': Operation not contemplated |
22 |
echo $? |
23 |
42 |
24 |
|
25 |
|
26 |
> jill-zeke /var/tmp $ rm -rf testdir |
27 |
> rm: cannot remove `testdir/test': Permission denied |
28 |
> jill-zeke /var/tmp $ echo $? |
29 |
> 1 |
30 |
> |
31 |
> |
32 |
> -- |
33 |
> Suddenly, the door crashed open. Outside, purple prose rained down |
34 |
> like a bad metaphor. |
35 |
> --SteveD on RPGnet |
36 |
> |
37 |
> |
38 |
> |