bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#24620: 26.0.50; In dired: 'dired-do-compress-to' fails when filename


From: José L . Doménech
Subject: bug#24620: 26.0.50; In dired: 'dired-do-compress-to' fails when filenames cotains space characters
Date: Thu, 27 Oct 2016 20:39:32 +0200
User-agent: Wanderlust/2.15.9 (Almost Unreal) SEMI-EPG/1.14.7 (Harue) FLIM/1.14.9 (Gojō) APEL/10.8 EasyPG/1.0.0 Emacs/26.0.50 (x86_64-pc-linux-gnu) MULE/6.0 (HANACHIRUSATO)

On Thu, 27 Oct 2016 19:34:49 +0200,
Michael Albinus wrote:
> 
> José L. Doménech <domenechjosel@gmail.com> writes:
> 
> Hi José,
> 
> > I wrote a little patch to get a workaround around dired having some
> > trouble compressing files with space characters in its name (bug
> > #24620).
> 
> Thanks for this!
> 
> > I am not sure if this will useful to someone. Please NOTE that I am
> > using apostrophes to surround the file name's. While it works on my
> > system (GNU/Linux) it could not work on other systems.
> 
> I believe it is better not to touch `dired-compress-files-alist'. Instead,
> at places where "%i and %o are replaced, one shall call
> `shell-quote-argument', as it is applied already in `dired-compress-file'.
>

I am getting a "replace-regexp-in-string: Invalid use of ‘\’ in replacement 
text"
error using 'shell-quote-argument' on this case.

It seems that 'shell-quoted-argument' is adding double '\', that is,
'\\', in front of the spaces instead of surrounding the argument with quotes.

And 'replace-match' which is called by 'replace-regexp-in-string' for the 
parameter
substitution ("%i", "%o") in the function 'dired-do-compress-to' doesn't like 
it.
  
> > Best Regards:
> > José L. Doménech
> 
> Best regards, Michael.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]