Re: [go-nuts] [ANN] go-scp: a scp client library in go

2016-09-20 Thread 'Paul Borman' via golang-nuts
For cancellation you run the actual operation in a goroutine and return results on a channel. You can then select on the Deadline from the context and the returned result. If the deadline hits, you just shut down the SSH session. Does that make sense? -Paul On Tue, Sep 20, 2016 at 3:36

Re: [go-nuts] [ANN] go-scp: a scp client library in go

2016-09-20 Thread Hiroaki Nakamura
2016-09-21 0:59 GMT+09:00 Paul Borman : > I would suggest just putting your package out there and see how it is > received. At some point, if it becomes the defacto package, moving it might > make sense. OK, I understood. > > I actually wrote an internal SCP package that

Re: [go-nuts] [ANN] go-scp: a scp client library in go

2016-09-20 Thread 'Paul Borman' via golang-nuts
I would suggest just putting your package out there and see how it is received. At some point, if it becomes the defacto package, moving it might make sense. I actually wrote an internal SCP package that works with a ssh multiplexer built on top of crypto/ssh. For various reasons, I am not in a

Re: [go-nuts] [ANN] go-scp: a scp client library in go

2016-09-20 Thread Hiroaki Nakamura
Hi Paul, Thanks for your feedback! 2016-09-20 0:02 GMT+09:00 Paul Borman : > Adding an scp package is a nice addition. I agree. Should I send a pull request to https://github.com/golang/crypto? If yes, what package? golang.org/x/crypto/scp or golang.org/x/crypto/ssh/scp? >

Re: [go-nuts] [ANN] go-scp: a scp client library in go

2016-09-19 Thread 'Paul Borman' via golang-nuts
Adding an scp package is a nice addition. You might want to consider simple names like: Send - Sends from []byte to file on remote host SendDir - Send files in dir to a remote host SendFile - Sends the contents of a file to the remote host Fetch - Fetches the contents of a file on remote host

[go-nuts] [ANN] go-scp: a scp client library in go

2016-09-16 Thread Hiroaki Nakamura
Hi all, I noticed the golang.org/x/crypto/ssh package exists, but the scp package does not. So I wrote a scp client library in go. https://github.com/hnakamur/go-scp I also wrote a sshd server just usable for testing go-scp. https://github.com/hnakamur/go-sshd Right now, go-scp only exports