unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Ivan Sokolov <ivan-p-sokolov@ya.ru>
Cc: 64531@debbugs.gnu.org, dgutov@yandex.ru
Subject: bug#64531: [PATCH v3] Add new commands for copying VC filenames
Date: Tue, 05 Sep 2023 14:01:56 +0300	[thread overview]
Message-ID: <83o7ig51ej.fsf@gnu.org> (raw)
In-Reply-To: <87a5u1em71.fsf@ya.ru> (message from Ivan Sokolov on Mon, 04 Sep 2023 23:08:02 +0300)

> From: Ivan Sokolov <ivan-p-sokolov@ya.ru>
> Cc: Eli Zaretskii <eliz@gnu.org>, Dmitry Gutov <dgutov@yandex.ru>
> Date: Mon, 04 Sep 2023 23:08:02 +0300
> 
> I tried to write documentation for the previous version of the command
> and came to the conclusion that I crammed too much functionality into
> it.  So I divided the DWIM command into command for copying name at
> point (bound to w) and command for copying marked files (bound to * w).
> 
> I also added new command for copying VC related filenames from
> everywhere.  An appropriate binding would be C-x v w, but I am not sure
> if I should use a top-level binding for such an insignificant command.
> 
> Quoting and prefix arguments now copy `dired-copy-filename-as-kill'.

Thanks, a few minor comments about the documentation parts:

> diff --git a/doc/emacs/maintaining.texi b/doc/emacs/maintaining.texi
> index 2dad70d3d13..8e7e2365f0a 100644
> --- a/doc/emacs/maintaining.texi
> +++ b/doc/emacs/maintaining.texi
> @@ -1388,6 +1388,13 @@ You can use this command to mark files that are in one of registered
>  states, including edited, added or removed.
>  (@code{vc-dir-mark-registered-files}).
>  
> +@findex vc-dir-copy-marked-files-as-kill
> +@item * w
> +This command copy names of marked files into the kill ring.  If prefix
                ^^^^
"copies"

> +argument is 0 names are absolute, with other prefix arguments names
> +are relative to the VC root directory.  Without prefix names are
> +relative to the VC buffer directory.

Our style is to describe the "normal" case first.  Like this:

  Normally, the copied file names are relative to the current buffer's
  default directory, but you can control that with the prefix
  argument.  With prefix argument of zero, the file names are copied
  in their absolute form; with any other value of prefix argument, the
  file names are relative to the root directory of the VCS repository.

> +@item w
> +Copy the name of the file at point into the kill ring.  If prefix
> +argument is 0 name is absolute, with other prefix arguments name is
> +relative to the VC root directory.  Without prefix name is relative to
> +the VC buffer directory.

This basically repeats the same text as above.  We usually first
describe the command in short, preferably in one sentence, and place
the detailed description further down.  Please try to follow these
conventions.





  reply	other threads:[~2023-09-05 11:01 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-07-08  7:51 bug#64531: [PATCH] Add new command vc-dir-copy-filename-as-kill Ivan Sokolov
2023-07-08  9:25 ` Eli Zaretskii
2023-08-08 13:44   ` bug#64531: [PATCH v2] " Ivan Sokolov
2023-08-08 13:56     ` Eli Zaretskii
2023-08-19  8:06     ` Eli Zaretskii
2023-08-19 23:12       ` Ivan Sokolov
2023-08-20  6:20         ` Eli Zaretskii
2023-08-19 23:33       ` Dmitry Gutov
2023-08-20  6:26         ` Eli Zaretskii
2023-08-20 10:26           ` Dmitry Gutov
2023-09-04 20:08 ` bug#64531: [PATCH v3] Add new commands for copying VC filenames Ivan Sokolov
2023-09-05 11:01   ` Eli Zaretskii [this message]
2023-10-19 23:39     ` Dmitry Gutov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=83o7ig51ej.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=64531@debbugs.gnu.org \
    --cc=dgutov@yandex.ru \
    --cc=ivan-p-sokolov@ya.ru \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).