* Re: master 838e6cae81: ; * etc/NEWS: Fix typos.
[not found] ` <20220916130718.0C2F6C026E1@vcs2.savannah.gnu.org>
@ 2022-09-16 13:27 ` Stefan Kangas
2022-09-16 13:37 ` Michael Albinus
0 siblings, 1 reply; 5+ messages in thread
From: Stefan Kangas @ 2022-09-16 13:27 UTC (permalink / raw)
To: Michael Albinus, emacs-devel
Michael Albinus <Michael.Albinus@gmx.de> writes:
> branch: master
> commit 838e6cae81392139377dd8b78b52ff3aaeba2fc1
> Author: Michael Albinus <michael.albinus@gmx.de>
> Commit: Michael Albinus <michael.albinus@gmx.de>
>
> ; * etc/NEWS: Fix typos.
Maybe we could write up a function for `emacs-news-mode' that catches
some of these mistakes? If it works well, we could even consider
sticking it in `before-save-hook'.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: master 838e6cae81: ; * etc/NEWS: Fix typos.
2022-09-16 13:27 ` master 838e6cae81: ; * etc/NEWS: Fix typos Stefan Kangas
@ 2022-09-16 13:37 ` Michael Albinus
2022-09-16 14:01 ` Stefan Kangas
2022-09-16 15:12 ` Stefan Monnier
0 siblings, 2 replies; 5+ messages in thread
From: Michael Albinus @ 2022-09-16 13:37 UTC (permalink / raw)
To: Stefan Kangas; +Cc: emacs-devel
[-- Attachment #1: Type: text/plain, Size: 561 bytes --]
Stefan Kangas <stefankangas@gmail.com> writes:
Hi Stefan,
>> ; * etc/NEWS: Fix typos.
>
> Maybe we could write up a function for `emacs-news-mode' that catches
> some of these mistakes? If it works well, we could even consider
> sticking it in `before-save-hook'.
Yes, I've discussed this with Eli some weeks ago, and he does agree. It
is just a matter of time for implementation. Something like checkdoc, ideally.
If you want to beat me (much appreciated!) I append my blurb for
checking. Just some code fragments, unordered.
Best regards, Michael.
[-- Attachment #2: NEWS-checklist --]
[-- Type: text/plain, Size: 1977 bytes --]
** A title shall always have a trailing period, except upper level titles
grep --color=auto -nH --null -E '^\*\*.*[^.:]$' NEWS
** A buffer name shall be placed in double apostrophs.
grep --color=auto -nH --null -E '(^|[^"])\*[^"\*]+\*[^*]' NEWS
** Check for comma in "Previously, "
grep --color=auto -nH --null -E 'Previously ' NEWS
** Check for wrong apostrophes
grep --color=auto -nH --null -E '[`‘’‚ˮ„“]' NEWS
** Check for quoting keystrokes
grep --color=auto -nH --null -E '"(C|M)-' NEWS
** Check for two spaces at sentence end
grep --color=auto -nH --null -E '[^ ]\. [^ ]' NEWS
** Check for two spaces otherwise
grep --color=auto -nH --null -E '[^.] ' NEWS
** Don't quote .el library names
grep --color=auto -nH --null -E "\.el'" NEWS
** Examples must start in column 4
grep --color=auto -nH --null -E "^( {1,3}| {5,})'?\(" NEWS
** 'M-x ... ' shall not use final RET
grep --color=auto -nH --null -E "RET'" NEWS
** 'M-x command' shall not be used for a single command
grep --color=auto -nH --null -E "'M-x [^[:space:]]+'" NEWS
** MIME types shall be enclosed in "..."
grep --color=auto -nH --null -E '[a-z]/[a-z]' NEWS
** Avoid double empty lines
pcregrep --color=auto -nH -M \$'\n\n\n' NEWS
** Don't use "behaviour" or "colour"
grep --color=auto -nH --null -E 'behaviour|colour' NEWS
** Keys must be enclosed with '...'
(occur "\\(^\\| \\)\\(TAB\\|RET\\|SPC\\|DEL\\|INS\\)" nil)
** Check for "GNU/Linux"
grep --color=auto -nH --null -E '(^| )Linux' NEWS
** Check for "it's", it must be "it is"
(occur "it's" nil)
** Check for "filename", it must be "file name"
(occur "filename" nil)
** Check for "doc string", it must be "docstring"
(occur "doc[[:space:]]+string" nil)
** Keywords (symbols starting with a colon) must be quoted
(occur "\\(^\\| \\):" nil)
** External program names shall be enclosed in "..."
nil ; No proper regexp :-(
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: master 838e6cae81: ; * etc/NEWS: Fix typos.
2022-09-16 13:37 ` Michael Albinus
@ 2022-09-16 14:01 ` Stefan Kangas
2022-09-16 14:06 ` Michael Albinus
2022-09-16 15:12 ` Stefan Monnier
1 sibling, 1 reply; 5+ messages in thread
From: Stefan Kangas @ 2022-09-16 14:01 UTC (permalink / raw)
To: Michael Albinus; +Cc: emacs-devel
Michael Albinus <Michael.Albinus@gmx.de> writes:
> Yes, I've discussed this with Eli some weeks ago, and he does agree. It
> is just a matter of time for implementation. Something like checkdoc, ideally.
>
> If you want to beat me (much appreciated!) I append my blurb for
> checking. Just some code fragments, unordered.
Thanks, that sounds great. I won't beat you to it, in all likelihood,
but any progress you can make here is much appreciated.
Maybe this could eventually be extended into checking also doc/**/*texi
for similar style errors? Or perhaps, for some of them, in the entire
tree?
Some minor comments:
> ** Don't use "behaviour" or "colour"
>
> grep --color=auto -nH --null -E 'behaviour|colour' NEWS
I should generally catch these (and more, see commit ba0871bef1e7) in my
periodic runs of codespell, but it can't hurt to have extra checks in
place. Perhaps I could document how I use codespell on the Emacs
sources, if that is of interest.
> ** Check for "it's", it must be "it is"
>
> (occur "it's" nil)
Do we accept "don't" and "can't"? I believe they are also frowned upon
in formal writing. (And what about "hasn't", and "haven't", etc.?)
> ** Check for "filename", it must be "file name"
>
> (occur "filename" nil)
>
> ** Check for "doc string", it must be "docstring"
>
> (occur "doc[[:space:]]+string" nil)
Also:
"data base" -> "database"
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: master 838e6cae81: ; * etc/NEWS: Fix typos.
2022-09-16 14:01 ` Stefan Kangas
@ 2022-09-16 14:06 ` Michael Albinus
0 siblings, 0 replies; 5+ messages in thread
From: Michael Albinus @ 2022-09-16 14:06 UTC (permalink / raw)
To: Stefan Kangas; +Cc: emacs-devel
Stefan Kangas <stefankangas@gmail.com> writes:
Hi Stefan,
> Some minor comments:
All of this agreed. My list is an ad hoc document: Whenever I have to
fix something at least twice, I add a rule.
Best regards, Michael.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: master 838e6cae81: ; * etc/NEWS: Fix typos.
2022-09-16 13:37 ` Michael Albinus
2022-09-16 14:01 ` Stefan Kangas
@ 2022-09-16 15:12 ` Stefan Monnier
1 sibling, 0 replies; 5+ messages in thread
From: Stefan Monnier @ 2022-09-16 15:12 UTC (permalink / raw)
To: Michael Albinus; +Cc: Stefan Kangas, emacs-devel
> Yes, I've discussed this with Eli some weeks ago, and he does agree. It
> is just a matter of time for implementation. Something like checkdoc, ideally.
Ideally hooked into `flymake-mode`.
Stefan
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2022-09-16 15:12 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <166333363759.20767.6682542392675900101@vcs2.savannah.gnu.org>
[not found] ` <20220916130718.0C2F6C026E1@vcs2.savannah.gnu.org>
2022-09-16 13:27 ` master 838e6cae81: ; * etc/NEWS: Fix typos Stefan Kangas
2022-09-16 13:37 ` Michael Albinus
2022-09-16 14:01 ` Stefan Kangas
2022-09-16 14:06 ` Michael Albinus
2022-09-16 15:12 ` Stefan Monnier
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.