Subject: Re: bug#25764: 26.0.50; Make some usability improvements to sieve-script management

From: Eric Abrahamsen <[email-masked]>
Date: Mon, 08 Jul 2019 16:51:58 -0700

"Basil L. Contovounesios" <[email-masked]> writes:

> I don't use sieve scripts, but I noticed a minor nit in your patch:
>
> Eric Abrahamsen <[email-masked]> writes:
>
>> @@ -215,6 +214,7 @@ sieve-edit-script
>>      (sieve-mode)
>>      (setq sieve-buffer-script-name name)
>>      (goto-char (point-min))
>> +    (set-buffer-modified-p nil)
>>      (message
>>       (substitute-command-keys
>>        "Press \\[sieve-upload] to upload script to server."))))
>
> [...]
>
>> @@ -350,11 +350,13 @@ sieve-upload
>>        (with-current-buffer (get-buffer sieve-buffer)
>>  	(setq err (sieve-manage-putscript
>>                     (or name sieve-buffer-script-name (buffer-name))
>> -                   script sieve-manage-buffer))
>> -	(if (sieve-manage-ok-p err)
>> -	    (message (substitute-command-keys
>> -		      "Sieve upload done.  Use \\[sieve-manage] to manage scripts."))
>> -	  (message "Sieve upload failed: %s" (nth 2 err)))))))
>> +                   script sieve-manage-buffer)))
>> +      (if (sieve-manage-ok-p err)
>> +          (progn
>> +            (message (substitute-command-keys
>> +                      "Sieve upload done.  Use \\[sieve-manage] to manage scripts."))
>> +            (set-buffer-modified-p nil))
>> +        (message "Sieve upload failed: %s" (nth 2 err))))))
>
> In both hunks, 'message' is given an arbitrary string as its first
> argument.  Any objections to the following cleanup of sieve.el text
> formatting code?

I do use sieve! But I didn't write this code. Your proposed chances seem
fine to me, though I'm wondering about the use of `ngettext' -- I saw
some arguments on these lists recently about international/localization,
and wasn't paying too much attention, but didn't see a clear resolution.
Is it the consensus that we're supposed to be using `ngettext' where possible?