Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implements multi-file upload and download #70

Conversation

Patches72790
Copy link

@Patches72790 Patches72790 commented Feb 23, 2023

This PR affects the following two issues tracked relating to multi-file upload/download in an ssh session. I implemented a similar approach to qcha0 (you'll have to take it on faith that this is my own independent work, but I was obviously influenced by some of their design decisions). However, since they don't seem to have been active for some time, I decided to go ahead and submit a PR for this. I have been using your go library (thank you by the way for implementing this great tool!) in one of my projects, and it would be very nice to have this feature as it simplifies my project's implementation significantly. The change mainly consists of just creating a new session with the ssh client each time you upload/download a file rather than keeping around the ssh session for the lifetime of the struct.

I added a test that uploads two files and downloads them subsequently to your tests folder, but I can add a couple more depending on what other edge cases I should cover.

This PR should close both issues #59 and #60 in your issue tracking.

Let me know if you need me to change anything or add anymore test coverage.

Thanks!

@Patches72790 Patches72790 changed the title Implements upload and download with single session Implements multi-file upload and download Feb 23, 2023
@bramvdbogaerde
Copy link
Owner

Thanks for your contributions. Looks good to me and solves a long-standing feature request. I am happy to merge this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants