How do I escape spaces in path for scp copy in Linux?

后端 未结 6 627
抹茶落季
抹茶落季 2020-11-30 17:13

I\'m new to linux, I want to copy a file from remote to local system... now I\'m using scp command in linux system.. I have some folders or files names are with spaces, when

6条回答
  •  时光取名叫无心
    2020-11-30 17:29

    Use 3 backslashes to escape spaces in names of directories:

    scp user@host:/path/to/directory\\\ with\\\ spaces/file ~/Downloads

    should copy to your Downloads directory the file from the remote directory called directory with spaces.

提交回复
热议问题