phingofficial/phing — pull request #176 by widmogrod (2012-12-28 20:03:54+00:00)
Title: ScpTask: fallback for "ssh2_scp_send" when remote server won't allow it.

Sometimes remote server allow only create files via sftp and won't allow scp.

For example: phpcloud.com
- how to deploy: http://www.phpcloud.com/help/sftp-help
- no possibility to login``` ssh someapp@someapp.my.phpcloud.com``` returns:

```
Connection to someapp.my.phpcloud.com closed.
Transferred: sent 2848, received 2344 bytes, in 1.6 seconds
Bytes per second: sent 1754.5, received 1444.0
debug1: Exit status 1
```

- no possibility to run ``` scp -v text.txt someapp@someapp.my.phpcloud.com:/c.txt``` which returns:

```
Transferred: sent 2544, received 2328 bytes, in 4.0 seconds
Bytes per second: sent 630.6, received 577.1
debug1: Exit status 128
lost connection
```

So, this pull request is my solution for this problem.
To do it as a separate task will only duplicate code, do I chose this solution.

What do you think of it?