Hi Antoine,
Antoine Jacoutot wrote on Mon, Dec 07, 2020 at 01:39:30PM +0100:
> On Mon, Dec 07, 2020 at 01:30:55PM +0100, Ingo Schwarze wrote:
>> Antoine Jacoutot wrote on Mon, Dec 07, 2020 at 01:01:27PM +0100:
>>> I just tested this change and it seems to work:
[...]
>> I think a slightly more explicit wording might make such a
>> misunderstanding less likely, for example:
>>
>> .Sh EXIT STATUS
>> .Ex -std syspatch
>> In particular, 2 indicates that applying patches was requested
>> but no additional patch was installed.
[...]
> Sure that's fine as well.
> I did change it to your initial proposal;
Thanks, but...
I initially documented what you originally implemented.
You changed what your implementation does, so the documentation
needed to change as well to match the second iteration of the
implementation.
> but careful, since you're a doc master
> I will put whatever you send my way ;-)
Sometimes, i am wrong, so i appreciate it when people read my
suggestions with a critical eye. Authors usually know their code
better than i do, and the documentation being correct is even
more important than being nicely worded and properly formatted. ;-)
> Index: syspatch.8
> ===================================================================
> RCS file: /cvs/src/usr.sbin/syspatch/syspatch.8,v
> retrieving revision 1.21
> diff -u -p -r1.21 syspatch.8
> --- syspatch.8 25 Jul 2020 15:45:44 -0000 1.21
> +++ syspatch.8 7 Dec 2020 12:39:07 -0000
> @@ -64,6 +64,8 @@ of installed patches.
> .El
> .Sh EXIT STATUS
> .Ex -std syspatch
> +In particular, 2 indicates that applying patches was requested but no
> +additional patch was installed.
> .Sh SEE ALSO
> .Xr signify 1 ,
> .Xr installurl 5 ,
> Index: syspatch.sh
> ===================================================================
> RCS file: /cvs/src/usr.sbin/syspatch/syspatch.sh,v
> retrieving revision 1.166
> diff -u -p -r1.166 syspatch.sh
> --- syspatch.sh 27 Oct 2020 17:42:05 -0000 1.166
> +++ syspatch.sh 7 Dec 2020 12:39:07 -0000
> @@ -320,6 +320,7 @@ if ((OPTIND == 1)); then
> [[ -f ${_D}/rollback.tgz ]] || rm -r ${_D}
> done
> _PATCHES=$(ls_missing) # can't use errexit in a for loop
> + [[ -n ${_PATCHES} ]] || exit 2
> for _PATCH in ${_PATCHES}; do
> apply_patch ${_OSrev}-${_PATCH}
> _PATCH_APPLIED=true