I think a better approach would be to always include $? in die messages
in Portage.
I think a better approach would be to always include $? in die messages
in Portage.
On Sun, Jun 25, 2023 at 2:52 PM Michał Górny <mgorny@gentoo.org> wrote:
I think a better approach would be to always include $? in die messages
in Portage.
It's a nice idea, but will not work in the case where die is not
called immediately after the failing command.
A couple of possible workarounds that could be used to reset $? before calling die:
1. Exit in a subshell: (exit ${status})
2. Return from a function: set_status() { return $1; }; set_status ${status}
In any case, I would like to apply the acct-user.eclass patch soonish
to help with debugging an error during stage building that releng
reported to me in IRC. We can revisit changing the die function and
possibly revert this patch later.
Sysop: | Keyop |
---|---|
Location: | Huddersfield, West Yorkshire, UK |
Users: | 475 |
Nodes: | 16 (2 / 14) |
Uptime: | 17:42:08 |
Calls: | 9,487 |
Calls today: | 6 |
Files: | 13,617 |
Messages: | 6,121,090 |