diff --git a/CHANGELOG.md b/CHANGELOG.md index 89ec27410..e86c3a4a8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -25,6 +25,7 @@ - Fixed creating non-existed `writable_dirs` [#1000](https://github.com/deployphp/deployer/pull/1000) - Fixed uploading files with spaces in a path via Native SSH [#1010](https://github.com/deployphp/deployer/issues/1010) - Fix merge of string array config options [#1067](https://github.com/deployphp/deployer/pull/1067) +- Fixed download of files when filename remote contains spaces [#1082](https://github.com/deployphp/deployer/pull/1082) ## v4.2.1 [v4.2.0...v4.2.1](https://github.com/deployphp/deployer/compare/v4.2.0...v4.2.1) diff --git a/src/Server/Remote/NativeSsh.php b/src/Server/Remote/NativeSsh.php index c33848dee..19e10f075 100644 --- a/src/Server/Remote/NativeSsh.php +++ b/src/Server/Remote/NativeSsh.php @@ -128,6 +128,8 @@ public function upload($local, $remote) */ public function download($local, $remote) { + $remote = str_replace(' ', '\ ', $remote); + $serverConfig = $this->getConfiguration(); $username = $serverConfig->getUser() ? $serverConfig->getUser() : null;