1 |
Dnia 2015-08-07, o godz. 21:42:59 |
2 |
Ulrich Mueller <ulm@g.o> napisał(a): |
3 |
|
4 |
> >>>>> On Fri, 7 Aug 2015, Michał Górny wrote: |
5 |
> |
6 |
> > The function can return one of the following return codes: |
7 |
> |
8 |
> > - 0 -- indicating that the package should be rebuilt from ebuild |
9 |
> > (changes occured), |
10 |
> |
11 |
> > - 1 -- indicating that the package needs not be rebuilt. |
12 |
> |
13 |
> > The function must use 'die' if an error preventing the function |
14 |
> > from determining the state occurs. |
15 |
> |
16 |
> Wouldn't it be feasible to leave error handling in that case to the |
17 |
> caller, i.e. have a third return code for the case there is some |
18 |
> failure? |
19 |
> https://bugs.gentoo.org/show_bug.cgi?id=482666#c2 |
20 |
|
21 |
What for? We need to support 'die' anyway, I don't see a reason to have |
22 |
two different variants of error reporting and magical exit codes. |
23 |
|
24 |
> > The function can output any user-oriented messages. The following |
25 |
> > output functions are made available: einfo, einfon, elog, ewarn, |
26 |
> > eerror, ebegin, eend. The following additional functions are |
27 |
> > available: die, assert, has, hasv, hasq. |
28 |
> |
29 |
> No use/usev/usex functions? There might be cases where a rebuild is |
30 |
> only needed for a certain combination of USE flags. |
31 |
|
32 |
I'd rather not implement all that in smart-live-rebuild. Maybe it'd |
33 |
make sense to have that in PM-implemented check in EAPI 7. |
34 |
|
35 |
-- |
36 |
Best regards, |
37 |
Michał Górny |
38 |
<http://dev.gentoo.org/~mgorny/> |