[darcs-devel] [patch1968] fix file path encoding in convert export command

Ben Franksen bugs at darcs.net
Sat Jul 4 21:23:12 UTC 2020


Ben Franksen <ben.franksen at online.de> added the comment:

I had forgotten that part of the patch was a change to the test, which I
wanted to make a bit more challenging. I had not expected the
redirection to a file with a strange name to fail on Windows. A fix that
rolls back the changes to the test script is attached.

__________________________________
Darcs bug tracker <bugs at darcs.net>
<http://bugs.darcs.net/patch1968>
__________________________________
-------------- next part --------------
1 patch for repository http://darcs.net/screened:

patch 510cccecfea591cd6452e67b2fbf467d85c87743
Author: Ben Franksen <ben.franksen at online.de>
Date:   Sat Jul  4 23:21:34 CEST 2020
  * rollback changes to tests/convert_export.sh
  
  These were half-hearted attempts to test the improvements in
  
  patch fe2dd87f789dfa0f6f4bbbc65cc9953a68c1e552
  Author: Ben Franksen <ben.franksen at online.de>
  Date:   Mon Jan 27 20:23:54 CET 2020
    * fix file path encoding in convert export command
  
  They break the test on Windows, though, because the redirection of the echo
  output fails.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256


New patches:

[rollback changes to tests/convert_export.sh
Ben Franksen <ben.franksen at online.de>**20200704212134
 Ignore-this: 94578650d300f526a0c1114211a2bbf37f10438ec559cbc7202295f57f93508daab21360e265b0b9
 
 These were half-hearted attempts to test the improvements in
 
 patch fe2dd87f789dfa0f6f4bbbc65cc9953a68c1e552
 Author: Ben Franksen <ben.franksen at online.de>
 Date:   Mon Jan 27 20:23:54 CET 2020
   * fix file path encoding in convert export command
 
 They break the test on Windows, though, because the redirection of the echo
 output fails.
] hunk ./tests/convert_export.sh 41
- -echo 'Liebe Grüße' > e/'"Liebe\ Grüße'
+echo 'Liebe Grüße' > e/'Liebe Grüße'
hunk ./tests/convert_export.sh 59
- -diff e/'"Liebe\ Grüße' gitmirror-clone/e/'"Liebe\ Grüße'
+diff e/"Liebe Grüße" gitmirror-clone/e/"Liebe Grüße"

Context:

[fix file path encoding in convert export command
Ben Franksen <ben.franksen at online.de>**20200127192354
 Ignore-this: 4777d7bcba190b94b71783075084c043665b97392b53bbdbad949f1ae74ecd3ff43a8a07ed198163
 
 This failed when the locale encoding is not UTF8, but file paths contain
 non-ASCII characters (such as tested in convert_export.sh). The reason is
 that we used anchorPath and then quoted the resulting String, which means we
 decodeLocale. Instead we have to use Darcs.Util.Path.flatten and do the
 quoting and escaping on the raw bytes. The test script was slightly extended
 to check that the quoting and escaping works as expected by git.
] 
[TAG 2.15.1
Ben Franksen <ben.franksen at online.de>**20190821065908
 Ignore-this: 4e9190f24c0c02b97865896d38e42743f7276dc9a3b28e0fa2a90086da5d6734cae6224e1a3141b5
] 
Patch bundle hash:
51e955dbec02b751b3098c90f7f07d7d6e77f262
-----BEGIN PGP SIGNATURE-----

iHUEAREIAB0WIQS1sLTEOCbYp4iyltnTbkUxbljMlwUCXwDz/wAKCRDTbkUxbljM
lxnnAQDGNkFNh0kjbBedwLO5E70hsfYB96sOcGPNNtwV1voOIgD/VLxXrQqU5XrE
ScqnShtQU+/9TkBDohXU9SHieaypDz8=
=ftTE
-----END PGP SIGNATURE-----


More information about the darcs-devel mailing list