public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* Latest versions of cygwin - Paths with spaces
@ 2022-05-18  0:00 Giovani Erthal
  2022-05-18  3:28 ` André Bleau
  2022-05-18 13:24 ` Giovani Erthal
  0 siblings, 2 replies; 6+ messages in thread
From: Giovani Erthal @ 2022-05-18  0:00 UTC (permalink / raw)
  To: cygwin

I'm using rsync to perform backups. But I have errors in paths with spaces.

Source: C:\Users\giova\Downloads\Teste com espaço
Destination: C:\Users\giova\Downloads\Destino com espaço

Command:

rsync.exe -avz -s --no-perms --no-owner --no-group --chmod=ugo=rw /cygdrive/C/Users/giova/Downloads/Teste" "com" "Espaço /cygdrive/C/Users/giova/Downloads/Destino" "com" "espaço

Result:

sending incremental file list
rsync: link_stat "/cygdrive/C/Users/giova/Downloads/Teste" "com" "Espaço" failed: No such file or directory (2)

sent 18 bytes  received 12 bytes  60.00 bytes/sec
total size is 0  speedup is 0.00
rsync error: some files/attrs were not transferred (see previous errors) (code 23) at main.c(1178) [sender=3.1.2]

Initially I was using cwrsync 6.2.4 (it has the same problem). Using cwrsync 5.5.0 everything works perfectly.

Now I downloaded cygwin and installed rsync (latest version), but the problem is the same.

How to make this work without using an old version of cygwin?

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Latest versions of cygwin - Paths with spaces
  2022-05-18  0:00 Latest versions of cygwin - Paths with spaces Giovani Erthal
@ 2022-05-18  3:28 ` André Bleau
  2022-05-18  4:04   ` Gary Johnson
  2022-05-18  5:49   ` Brian Inglis
  2022-05-18 13:24 ` Giovani Erthal
  1 sibling, 2 replies; 6+ messages in thread
From: André Bleau @ 2022-05-18  3:28 UTC (permalink / raw)
  To: cygwin

Hi Giovani.

Giovani Erthal wrote:
 
> I'm using rsync to perform backups. But I have errors in paths with spaces.
> 
> Source: C:\Users\giova\Downloads\Teste com espaço
> Destination: C:\Users\giova\Downloads\Destino com espaço
> 
> Command:
> 
> rsync.exe -avz -s --no-perms --no-owner --no-group --chmod=ugo=rw /cygdrive/C/Users/giova/Downloads/Teste" 
> 
> "com" "Espaço /cygdrive/C/Users/giova/Downloads/Destino" "com" "espaço

Wrong space quoting. Try:

rsync.exe -avz -s --no-perms --no-owner --no-group --chmod=ugo=rw "/cygdrive/C/Users/giova/Downloads/Teste com Espaço" "/cygdrive/C/Users/giova/Downloads/Destino com espaço"

> 
> Result:
> 
> sending incremental file list
> rsync: link_stat "/cygdrive/C/Users/giova/Downloads/Teste" "com" "Espaço" failed: No such file or directory (2)
> 
> sent 18 bytes  received 12 bytes  60.00 bytes/sec
> total size is 0  speedup is 0.00
> rsync error: some files/attrs were not transferred (see previous errors) (code 23) at main.c(1178) [sender=3.1.2]
> 
> Initially I was using cwrsync 6.2.4 (it has the same problem). Using cwrsync 5.5.0 everything works perfectly.
> 
> Now I downloaded cygwin and installed rsync (latest version), but the problem is the same.
> 
> How to make this work without using an old version of cygwin?

Regards,

- André Bleau

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Latest versions of cygwin - Paths with spaces
  2022-05-18  3:28 ` André Bleau
@ 2022-05-18  4:04   ` Gary Johnson
  2022-05-18  5:49   ` Brian Inglis
  1 sibling, 0 replies; 6+ messages in thread
From: Gary Johnson @ 2022-05-18  4:04 UTC (permalink / raw)
  To: cygwin

On 2022-05-18, André Bleau wrote:
> Hi Giovani.
> 
> Giovani Erthal wrote:
>  
> > I'm using rsync to perform backups. But I have errors in paths with spaces.
> > 
> > Source: C:\Users\giova\Downloads\Teste com espaço
> > Destination: C:\Users\giova\Downloads\Destino com espaço
> > 
> > Command:
> > 
> > rsync.exe -avz -s --no-perms --no-owner --no-group --chmod=ugo=rw /cygdrive/C/Users/giova/Downloads/Teste" 
> > 
> > "com" "Espaço /cygdrive/C/Users/giova/Downloads/Destino" "com" "espaço
> 
> Wrong space quoting. Try:
> 
> rsync.exe -avz -s --no-perms --no-owner --no-group --chmod=ugo=rw "/cygdrive/C/Users/giova/Downloads/Teste com Espaço" "/cygdrive/C/Users/giova/Downloads/Destino com espaço"

André's quoting is unusual, but it's not wrong.

For example:

    $ cat foo
    #!/bin/bash
    for word in "$@"
    do
        echo "$word"
    done

    $ ./foo one two" "three four
    one
    two three
    four

However, I've always seen the C: drive under /cygdrive as
/cygdrive/c, with a lower-case c.

Regards,
Gary


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Latest versions of cygwin - Paths with spaces
  2022-05-18  3:28 ` André Bleau
  2022-05-18  4:04   ` Gary Johnson
@ 2022-05-18  5:49   ` Brian Inglis
  1 sibling, 0 replies; 6+ messages in thread
From: Brian Inglis @ 2022-05-18  5:49 UTC (permalink / raw)
  To: cygwin


On 2022-05-17 21:28, André Bleau wrote:
> Giovani Erthal wrote:
>> I'm using rsync to perform backups. But I have errors in paths with spaces.
>> Source: C:\Users\giova\Downloads\Teste com espaço
>> Destination: C:\Users\giova\Downloads\Destino com espaço
>> Command:
>> rsync.exe -avz -s --no-perms --no-owner --no-group --chmod=ugo=rw
/cygdrive/C/Users/giova/Downloads/Teste"
>> "com" "Espaço /cygdrive/C/Users/giova/Downloads/Destino" "com" 
>> "espaço

> Wrong space quoting. Try:
> rsync.exe -avz -s --no-perms --no-owner --no-group --chmod=ugo=rw "/cygdrive/C/Users/giova/Downloads/Teste com Espaço" "/cygdrive/C/Users/giova/Downloads/Destino com espaço"

>> Result:
>> sending incremental file list
>> rsync: link_stat "/cygdrive/C/Users/giova/Downloads/Teste" "com" "Espaço" failed: No such file or directory (2)
>> sent 18 bytes  received 12 bytes  60.00 bytes/sec
>> total size is 0  speedup is 0.00
>> rsync error: some files/attrs were not transferred (see previous errors) (code 23) at main.c(1178) [sender=3.1.2]
>> Initially I was using cwrsync 6.2.4 (it has the same problem). Using cwrsync 5.5.0 everything works perfectly.
>> Now I downloaded cygwin and installed rsync (latest version), but the problem is the same.
>> How to make this work without using an old version of cygwin?

What shell are you using and what OS is handling command processing?
For CMD and Windows, you must to double quote the whole path.
For bash and Cygwin, you may use any of the accepted methods: \ , " ",
' ', although it is much more normal, if quoting, to quote the complete 
path, or only backslash quote the spaces and other special characters.
Drive case should make no difference as long as case is ignored on lookup.

-- 
Take care. Thanks, Brian Inglis, Calgary, Alberta, Canada

This email may be disturbing to some readers as it contains
too much technical detail. Reader discretion is advised.
[Data in binary units and prefixes, physical quantities in SI.]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* RE: Latest versions of cygwin - Paths with spaces
  2022-05-18  0:00 Latest versions of cygwin - Paths with spaces Giovani Erthal
  2022-05-18  3:28 ` André Bleau
@ 2022-05-18 13:24 ` Giovani Erthal
  2022-05-18 15:38   ` Thomas Wolff
  1 sibling, 1 reply; 6+ messages in thread
From: Giovani Erthal @ 2022-05-18 13:24 UTC (permalink / raw)
  To: cygwin

I'm using the windows terminal.

Using lowercase for the drive and double quotes between the path produces a different error.

rsync.exe -avz -s --no-perms --no-owner --no-group --chmod=ugo=rw "/cygdrive/c/Users/giova/Downloads/Teste com Espaço" "/cygdrive/c/Users/giova/Downloads/Destino com espaço"

sending incremental file list
rsync: [sender] change_dir "/cygdrive/c/Users/giova/"/cygdrive/c/Users/giova/Downloads" failed: No such file or directory (2)
rsync: [Receiver] change_dir#3 "/cygdrive/c/Users/giova/"/cygdrive/c/Users/giova/Downloads" failed: No such file or directory (2)
rsync error: errors selecting input/output files, dirs (code 3) at main.c(822) [Receiver=3.2.4dev]
________________________________
De: Giovani Erthal
Enviado: terça-feira, 17 de maio de 2022 21:00
Para: cygwin@cygwin.com <cygwin@cygwin.com>
Assunto: Latest versions of cygwin - Paths with spaces

I'm using rsync to perform backups. But I have errors in paths with spaces.

Source: C:\Users\giova\Downloads\Teste com espaço
Destination: C:\Users\giova\Downloads\Destino com espaço

Command:

rsync.exe -avz -s --no-perms --no-owner --no-group --chmod=ugo=rw /cygdrive/C/Users/giova/Downloads/Teste" "com" "Espaço /cygdrive/C/Users/giova/Downloads/Destino" "com" "espaço

Result:

sending incremental file list
rsync: link_stat "/cygdrive/C/Users/giova/Downloads/Teste" "com" "Espaço" failed: No such file or directory (2)

sent 18 bytes  received 12 bytes  60.00 bytes/sec
total size is 0  speedup is 0.00
rsync error: some files/attrs were not transferred (see previous errors) (code 23) at main.c(1178) [sender=3.1.2]

Initially I was using cwrsync 6.2.4 (it has the same problem). Using cwrsync 5.5.0 everything works perfectly.

Now I downloaded cygwin and installed rsync (latest version), but the problem is the same.

How to make this work without using an old version of cygwin?

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Latest versions of cygwin - Paths with spaces
  2022-05-18 13:24 ` Giovani Erthal
@ 2022-05-18 15:38   ` Thomas Wolff
  0 siblings, 0 replies; 6+ messages in thread
From: Thomas Wolff @ 2022-05-18 15:38 UTC (permalink / raw)
  To: cygwin



Am 18.05.2022 um 15:24 schrieb Giovani Erthal:
> I'm using the windows terminal.
So you call cygwin rsync directly from the Windows cmd or powershell? 
That is asking for trouble, especially if quoting is involved. You 
should call rsync from a cygwin shell.
>
> Using lowercase for the drive and double quotes between the path produces a different error.
>
> rsync.exe -avz -s --no-perms --no-owner --no-group --chmod=ugo=rw "/cygdrive/c/Users/giova/Downloads/Teste com Espaço" "/cygdrive/c/Users/giova/Downloads/Destino com espaço"
>
> sending incremental file list
> rsync: [sender] change_dir "/cygdrive/c/Users/giova/"/cygdrive/c/Users/giova/Downloads" failed: No such file or directory (2)
> rsync: [Receiver] change_dir#3 "/cygdrive/c/Users/giova/"/cygdrive/c/Users/giova/Downloads" failed: No such file or directory (2)
> rsync error: errors selecting input/output files, dirs (code 3) at main.c(822) [Receiver=3.2.4dev]
> ________________________________
> De: Giovani Erthal
> Enviado: terça-feira, 17 de maio de 2022 21:00
> Para: cygwin@cygwin.com <cygwin@cygwin.com>
> Assunto: Latest versions of cygwin - Paths with spaces
>
> I'm using rsync to perform backups. But I have errors in paths with spaces.
>
> Source: C:\Users\giova\Downloads\Teste com espaço
> Destination: C:\Users\giova\Downloads\Destino com espaço
>
> Command:
>
> rsync.exe -avz -s --no-perms --no-owner --no-group --chmod=ugo=rw /cygdrive/C/Users/giova/Downloads/Teste" "com" "Espaço /cygdrive/C/Users/giova/Downloads/Destino" "com" "espaço
>
> Result:
>
> sending incremental file list
> rsync: link_stat "/cygdrive/C/Users/giova/Downloads/Teste" "com" "Espaço" failed: No such file or directory (2)
>
> sent 18 bytes  received 12 bytes  60.00 bytes/sec
> total size is 0  speedup is 0.00
> rsync error: some files/attrs were not transferred (see previous errors) (code 23) at main.c(1178) [sender=3.1.2]
>
> Initially I was using cwrsync 6.2.4 (it has the same problem). Using cwrsync 5.5.0 everything works perfectly.
>
> Now I downloaded cygwin and installed rsync (latest version), but the problem is the same.
>
> How to make this work without using an old version of cygwin?
>


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2022-05-18 15:38 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-05-18  0:00 Latest versions of cygwin - Paths with spaces Giovani Erthal
2022-05-18  3:28 ` André Bleau
2022-05-18  4:04   ` Gary Johnson
2022-05-18  5:49   ` Brian Inglis
2022-05-18 13:24 ` Giovani Erthal
2022-05-18 15:38   ` Thomas Wolff

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).