Patch 1633 Resolve issue2545: prepend "--" to non-option arguments in ssh invocation

Title Resolve issue2545: prepend "--" to non-option arguments in ssh invocation
Superseder Nosy List gpiero
Related Issues
Status accepted Assigned To

Created on 2018-01-06.07:17:30 by gpiero, last changed 2018-03-15.19:10:04 by gh.

File name Status Uploaded Type Edit Remove
adapt-transfer_mode-test-to-new-debug-message-arguments-escaping.dpatch gh, 2018-02-07.21:29:57 application/octet-stream
improve-debug-messages-about-invocation-of-external-ssh-commands.dpatch gpiero, 2018-01-08.19:25:51 application/octet-stream
issue2545_command-execution-via-ssh-uri.sh-portability-fix.dpatch gpiero, 2018-01-08.19:29:20 application/octet-stream
tests_sshlib_-add-a-helper-function-for-initializing-a-remote-repo.dpatch gpiero, 2018-01-06.07:17:29 application/octet-stream
See mailing list archives for discussion on individual patches.
msg19817 (view) Author: gpiero Date: 2018-01-06.07:17:29
patch 315bc9fb58ce4245be4bb443d29ae3d1fccd2257 is named '* Resolve
...' in order to automatically close the bug (and because it effectively
the issue:).
Anyway I plan to send a more comprehensive patch that will not allow
host names
starting with a '-'. That is the same approach used by git, svn and,
IIRC, hg.
The rationale is that the use of '--' for signaling end of options is
implementation-dependent (well, so is the use of '-' as the first char of an
option). Given that AFAIK a host name starting with '-' is invalid as per
RFC-1123, I don't see any problems in implementing it also in darcs.

At last, git also disabled repositories starting with a '-'. While not
the best
choice for naming a directory (at least on POSIX), I think (but not
checked) that such a dir name would not create problems in darcs and I'm not
leaning to support this restriction.
msg19819 (view) Author: gpiero Date: 2018-01-08.19:25:51
patch 4ecf394c343d80f68c25d53bc1acf2eed1bd0a27
Author: Gian Piero Carrubba <gpiero@rm-rf.it>
Date:   Mon Jan  8 13:57:46 CET 2018
  * Fix test broken by patch 8706d6e70c1aa572f383882c371a9bafbec3dc38
  (Improve debug messages about invocation of external SSH commands)
msg19820 (view) Author: gpiero Date: 2018-01-08.19:29:20
patch 1b543dc9c0e2ca4ced934e58eed081c3f69c5627
Author: Gian Piero Carrubba <gpiero@rm-rf.it>
Date:   Mon Jan  8 20:12:29 CET 2018
  * t/n/issue2545_command-execution-via-ssh-uri.sh: portability fix
msg19826 (view) Author: gh Date: 2018-01-21.20:55:20
Hi Gian Piero,

your patches look sensible in principle, so I'm screening them. Thanks
for addressing issue2545 ; this is definitely something we want in the
next stable release.

Just so you know, `darcs init '$repodir'` is accepted, it is equivalent
to `darcs init --repo '$repodir'`.

msg19833 (view) Author: gh Date: 2018-02-07.21:29:57
A followup patch:

1 patch for repository http://darcs.net:

patch 724791e562535703e8b9fd552fa875f07e79baf8
Author: Guillaume Hoffmann <guillaumh@gmail.com>
Date:   Wed Feb  7 18:27:44 -03 2018
  * adapt transfer-mode test to new debug message arguments escaping
msg19973 (view) Author: gh Date: 2018-03-15.19:10:04
Looks good, accepted.
Date User Action Args
2018-01-06 07:17:30gpierocreate
2018-01-08 19:25:51gpierosetfiles: + improve-debug-messages-about-invocation-of-external-ssh-commands.dpatch
messages: + msg19819
2018-01-08 19:29:20gpierosetfiles: + issue2545_command-execution-via-ssh-uri.sh-portability-fix.dpatch
messages: + msg19820
2018-01-21 20:55:20ghsetstatus: needs-screening -> needs-review
messages: + msg19826
2018-02-07 21:29:57ghsetfiles: + adapt-transfer_mode-test-to-new-debug-message-arguments-escaping.dpatch
messages: + msg19833
2018-03-15 19:10:04ghsetstatus: needs-review -> accepted
messages: + msg19973